Software / code / prosody
Comparison
plugins/mod_storage_sql.lua @ 10700:3fce670e0733 0.11
mod_storage_sql: Add index covering sort_id to improve performance (fixes #1505)
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Sun, 22 Mar 2020 21:05:59 +0100 |
| parent | 10655:ee6c12264420 |
| child | 10701:929c95e518f0 |
comparison
equal
deleted
inserted
replaced
| 10699:fd77b6cec38d | 10700:3fce670e0733 |
|---|---|
| 498 Column { name="type", type="TEXT", nullable=false }; | 498 Column { name="type", type="TEXT", nullable=false }; |
| 499 Column { name="value", type="MEDIUMTEXT", nullable=false }; | 499 Column { name="value", type="MEDIUMTEXT", nullable=false }; |
| 500 Index { name="prosodyarchive_index", unique = engine.params.driver ~= "MySQL", "host", "user", "store", "key" }; | 500 Index { name="prosodyarchive_index", unique = engine.params.driver ~= "MySQL", "host", "user", "store", "key" }; |
| 501 Index { name="prosodyarchive_with_when", "host", "user", "store", "with", "when" }; | 501 Index { name="prosodyarchive_with_when", "host", "user", "store", "with", "when" }; |
| 502 Index { name="prosodyarchive_when", "host", "user", "store", "when" }; | 502 Index { name="prosodyarchive_when", "host", "user", "store", "when" }; |
| 503 Index { name="prosodyarchive_sort", "host", "user", "store", "sort_id" }; | |
| 503 }; | 504 }; |
| 504 engine:transaction(function() | 505 engine:transaction(function() |
| 505 ProsodyArchiveTable:create(engine); | 506 ProsodyArchiveTable:create(engine); |
| 506 end); | 507 end); |
| 507 end | 508 end |