aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_storage_sql.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2017-11-21 14:46:21 +0100
committerKim Alvefur <zash@zash.se>2017-11-21 14:46:21 +0100
commita7693939d4e64dba7b80d5705c25e53b4602a935 (patch)
treef51a1b39c0c31f340a04b84c8b7c2b24f518f277 /plugins/mod_storage_sql.lua
parent0158bad7ad35279d64096ee86defdf4c04532ece (diff)
downloadprosody-a7693939d4e64dba7b80d5705c25e53b4602a935.tar.gz
prosody-a7693939d4e64dba7b80d5705c25e53b4602a935.zip
mod_storage_sql: Add indices that include the with and when columns of archives
Diffstat (limited to 'plugins/mod_storage_sql.lua')
-rw-r--r--plugins/mod_storage_sql.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/mod_storage_sql.lua b/plugins/mod_storage_sql.lua
index c729c66a..e25cb5c6 100644
--- a/plugins/mod_storage_sql.lua
+++ b/plugins/mod_storage_sql.lua
@@ -452,6 +452,8 @@ local function create_table(engine, name) -- luacheck: ignore 431/engine
Column { name="type", type="TEXT", nullable=false };
Column { name="value", type="MEDIUMTEXT", nullable=false };
Index { name="prosodyarchive_index", unique = true, "host", "user", "store", "key" };
+ Index { name="prosodyarchive_with", "host", "user", "store", "with" };
+ Index { name="prosodyarchive_when", "host", "user", "store", "when" };
};
engine:transaction(function()
ProsodyArchiveTable:create(engine);