mirror of
https://github.com/matrix-org/dendrite
synced 2024-12-14 06:23:49 +01:00
Add missing indexes to federation API destination queues (#2502)
* Add missing indexes to federation API destination queues * Fix duplicate name
This commit is contained in:
parent
500124dd18
commit
247604979a
6 changed files with 22 additions and 0 deletions
|
@ -36,6 +36,10 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_edus (
|
|||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_edus_json_nid_idx
|
||||
ON federationsender_queue_edus (json_nid, server_name);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_edus_nid_idx
|
||||
ON federationsender_queue_edus (json_nid);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_edus_server_name_idx
|
||||
ON federationsender_queue_edus (server_name);
|
||||
`
|
||||
|
||||
const insertQueueEDUSQL = "" +
|
||||
|
|
|
@ -33,6 +33,9 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_json (
|
|||
-- The JSON body. Text so that we preserve UTF-8.
|
||||
json_body TEXT NOT NULL
|
||||
);
|
||||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_json_json_nid_idx
|
||||
ON federationsender_queue_json (json_nid);
|
||||
`
|
||||
|
||||
const insertJSONSQL = "" +
|
||||
|
|
|
@ -36,6 +36,10 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_pdus (
|
|||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_pdus_pdus_json_nid_idx
|
||||
ON federationsender_queue_pdus (json_nid, server_name);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_pdus_json_nid_idx
|
||||
ON federationsender_queue_pdus (json_nid);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_pdus_server_name_idx
|
||||
ON federationsender_queue_pdus (server_name);
|
||||
`
|
||||
|
||||
const insertQueuePDUSQL = "" +
|
||||
|
|
|
@ -37,6 +37,10 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_edus (
|
|||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_edus_json_nid_idx
|
||||
ON federationsender_queue_edus (json_nid, server_name);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_edus_nid_idx
|
||||
ON federationsender_queue_edus (json_nid);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_edus_server_name_idx
|
||||
ON federationsender_queue_edus (server_name);
|
||||
`
|
||||
|
||||
const insertQueueEDUSQL = "" +
|
||||
|
|
|
@ -35,6 +35,9 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_json (
|
|||
-- The JSON body. Text so that we preserve UTF-8.
|
||||
json_body TEXT NOT NULL
|
||||
);
|
||||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_json_json_nid_idx
|
||||
ON federationsender_queue_json (json_nid);
|
||||
`
|
||||
|
||||
const insertJSONSQL = "" +
|
||||
|
|
|
@ -38,6 +38,10 @@ CREATE TABLE IF NOT EXISTS federationsender_queue_pdus (
|
|||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS federationsender_queue_pdus_pdus_json_nid_idx
|
||||
ON federationsender_queue_pdus (json_nid, server_name);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_pdus_json_nid_idx
|
||||
ON federationsender_queue_pdus (json_nid);
|
||||
CREATE INDEX IF NOT EXISTS federationsender_queue_pdus_server_name_idx
|
||||
ON federationsender_queue_pdus (server_name);
|
||||
`
|
||||
|
||||
const insertQueuePDUSQL = "" +
|
||||
|
|
Loading…
Reference in a new issue