synapse-product/synapse/storage
Sean Quah b2c2b03079
Fix PostgreSQL sometimes using table scans for event_search (#14409)
PostgreSQL may underestimate the number of distinct `room_id`s in
`event_search`, which can cause it to use table scans for queries for
multiple rooms.

Fix this by setting `n_distinct` on the column.

Resolves #14402.

Signed-off-by: Sean Quah <seanq@matrix.org>
2022-11-10 19:02:27 +00:00
..
controllers Fix performance regression in get_users_in_room (#13972) 2022-09-30 13:15:32 +01:00
databases Drop support for Postgres 10 in full text search code. (#14397) 2022-11-09 09:55:34 -05:00
engines Drop support for Postgres 10 in full text search code. (#14397) 2022-11-09 09:55:34 -05:00
schema Fix PostgreSQL sometimes using table scans for event_search (#14409) 2022-11-10 19:02:27 +00:00
util Cancel the processing of key query requests when they time out. (#13680) 2022-09-07 12:03:32 +01:00
__init__.py Rename storage classes (#12913) 2022-05-31 12:17:50 +00:00
_base.py Bump flake8-bugbear from 22.9.23 to 22.10.27 (#14329) 2022-11-04 18:43:14 +00:00
background_updates.py Generate separate snapshots for logical databases (#13792) 2022-09-20 14:14:12 +01:00
database.py When restarting a partial join resync, prioritise the server which actioned a partial join (#14126) 2022-10-18 12:33:18 +01:00
keys.py Use auto_attribs/native type hints for attrs classes. (#11692) 2022-01-13 13:49:28 +00:00
prepare_database.py Snapshot schema 72 (#13873) 2022-09-26 18:28:32 +01:00
push_rule.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
roommember.py Do not include rooms with an unknown room version in a sync response. (#10644) 2021-08-19 11:12:55 -04:00
state.py Update the rejected state of events during resync (#13459) 2022-08-11 10:42:24 +00:00
types.py Tidy up and type-hint the database engine modules (#12734) 2022-05-17 00:34:38 +01:00