zulip/zilencer/migrations
Alex Vandiver 902498ec4f zilencer: Update remoterealm indexes.
There is no reason to have an index on just `realm_id` or `remote_id`,
as those values mean nothing outside of the scope of a specific
`server_id`.  Remove those never-used single-column indexes from the
two tables that have them.

By contrast, the pair of `server_id` and `remote_id` is quite useful
and specific -- it is a unique pair, and every POST of statistics from
a remote host requires looking up the highest `remote_id` for a given
`server_id`, which (without this index) is otherwise a quite large
scan.

Add a unique constraint, which (in PostgreSQL) is implemented as a
unique index.
2023-09-14 09:30:16 -07:00
..
0001_initial.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0002_remote_zulip_server.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0003_add_default_for_remotezulipserver_last_updated_field.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0004_remove_deployment_model.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0005_remotepushdevicetoken_fix_uniqueness.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0006_customer.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0007_remotezulipserver_fix_uniqueness.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0008_customer_billing_user.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0009_plan.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0010_billingprocessor.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0011_customer_has_billing_relationship.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0012_coupon.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0013_remove_customer_billing_user.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0014_cleanup_pushdevicetoken.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0015_delete_billing.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0016_remote_counts.py models: Convert deprecated index_together option to indexes. 2023-07-12 07:12:43 -07:00
0017_installationcount_indexes.py models: Convert deprecated index_together option to indexes. 2023-07-12 07:12:43 -07:00
0018_remoterealmauditlog.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0019_remotezulipserver_plan_type.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0020_remotezulipserverauditlog.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0021_alter_remotezulipserver_uuid.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0022_remotezulipserver_create_audit_log_backfill.py migrations: Import BaseDatabaseSchemaEditor from its canonical module. 2023-03-05 14:46:28 -08:00
0023_remotezulipserver_deactivated.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0024_remotepushdevicetoken_user_uuid.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0025_alter_remotepushdevicetoken_user_id_drop_index.py black: Reformat with Black 23. 2023-02-02 10:40:13 -08:00
0026_auditlog_models_extra_data_json.py migration: Add `extra_data_json` for audit log models. 2023-06-07 12:14:43 -07:00
0027_backfill_remote_realmauditlog_extradata_to_json_field.py mypy: Upgrade mypy from 1.4.1 to 1.5.1. 2023-09-07 17:51:42 -07:00
0028_rename_extradatajson_remoteauditlog_extra_data.py migration: Rename extra_data_json to extra_data in audit log models. 2023-08-16 17:18:14 -07:00
0029_update_remoterealm_indexes.py zilencer: Update remoterealm indexes. 2023-09-14 09:30:16 -07:00
__init__.py