add combined index for item.uid and item.item_unseen. this speeds up notifications by a magnitude.

This commit is contained in:
Mario Vavti
2017-09-01 21:27:59 +02:00
parent 3af3b36db3
commit e935473c5c
7 changed files with 27 additions and 11 deletions

View File

@@ -650,8 +650,9 @@ CREATE TABLE IF NOT EXISTS `item` (
KEY `created` (`created`),
KEY `edited` (`edited`),
KEY `received` (`received`),
KEY `uid_commented` (`uid`,`commented`),
KEY `uid_created` (`uid`,`created`),
KEY `uid_commented` (`uid`, `commented`),
KEY `uid_created` (`uid`, `created`),
KEY `uid_item_unseen` (`uid`, `item_unseen`);
KEY `aid` (`aid`),
KEY `owner_xchan` (`owner_xchan`),
KEY `author_xchan` (`author_xchan`),