anonymousland-synapse/changelog.d
Eric Eastwood 29269d9d3f
Fix have_seen_event cache not being invalidated (#13863)
Fix https://github.com/matrix-org/synapse/issues/13856
Fix https://github.com/matrix-org/synapse/issues/13865

> Discovered while trying to make Synapse fast enough for [this MSC2716 test for importing many batches](https://github.com/matrix-org/complement/pull/214#discussion_r741678240). As an example, disabling the `have_seen_event` cache saves 10 seconds for each `/messages` request in that MSC2716 Complement test because we're not making as many federation requests for `/state` (speeding up `have_seen_event` itself is related to https://github.com/matrix-org/synapse/issues/13625) 
> 
> But this will also make `/messages` faster in general so we can include it in the [faster `/messages` milestone](https://github.com/matrix-org/synapse/milestone/11).
> 
> *-- https://github.com/matrix-org/synapse/issues/13856*


### The problem

`_invalidate_caches_for_event` doesn't run in monolith mode which means we never even tried to clear the `have_seen_event` and other caches. And even in worker mode, it only runs on the workers, not the master (AFAICT).

Additionally there was bug with the key being wrong so `_invalidate_caches_for_event` never invalidates the `have_seen_event` cache even when it does run.

Because we were using the `@cachedList` wrong, it was putting items in the cache under keys like `((room_id, event_id),)` with a `set` in a `set` (ex. `(('!TnCIJPKzdQdUlIyXdQ:test', '$Iu0eqEBN7qcyF1S9B3oNB3I91v2o5YOgRNPwi_78s-k'),)`) and we we're trying to invalidate with just `(room_id, event_id)` which did nothing.
2022-09-27 15:55:43 -05:00
..
.gitignore Correct attrs package name in requirements (#3492) 2018-07-07 10:46:59 +10:00
13635.feature Only try to backfill event if we haven't tried before recently (#13635) 2022-09-23 14:01:29 -05:00
13667.feature Add cache invalidation across workers to module API (#13667) 2022-09-21 15:32:01 +02:00
13722.feature Implementation of MSC3882 login token request (#13722) 2022-09-21 15:12:29 +00:00
13768.misc Port the push rule classes to Rust. (#13768) 2022-09-20 12:10:31 +01:00
13772.doc Add worker_main_http_uri to the contrib bash script (#13772) 2022-09-21 15:58:46 +01:00
13782.feature Accept & store thread IDs for receipts (implement MSC3771). (#13782) 2022-09-23 14:33:28 +00:00
13792.misc Generate separate snapshots for logical databases (#13792) 2022-09-20 14:14:12 +01:00
13796.misc Simplify cache invalidation after event persist txn (#13796) 2022-09-26 16:26:35 +01:00
13799.feature Support enabling/disabling pushers (from MSC3881) (#13799) 2022-09-21 14:39:01 +00:00
13809.misc Improve the synapse.api.auth.Auth mock used in unit tests. (#13809) 2022-09-21 12:40:34 +00:00
13818.doc Update NixOS module URL (#13818) 2022-09-26 15:26:59 +01:00
13823.misc Faster Remote Room Joins: tell remote homeservers that we are unable to authorise them if they query a room which has partial state on our server. (#13823) 2022-09-23 11:47:16 +01:00
13830.bugfix typing: check origin server of typing event against room's servers (#13830) 2022-09-26 17:33:32 +02:00
13831.feature Track device IDs for pushers (#13831) 2022-09-21 15:31:53 +00:00
13832.feature Last batch of Pydantic for synapse/rest/client/account.py (#13832) 2022-09-21 22:23:44 +01:00
13836.doc Correct documentation for map_user_attributes of OpenID Mapping Providers (#13836) 2022-09-21 13:08:16 +00:00
13839.misc Carry IdP Session IDs through user-mapping sessions. (#13839) 2022-09-27 14:38:14 +01:00
13840.bugfix Properly paginate forward in the /relations API. (#13840) 2022-09-22 12:47:49 +00:00
13843.removal Remove the complete_sso_login method from the Module API which was deprecated in Synapse 1.13.0. (#13843) 2022-09-20 15:18:07 +02:00
13850.misc Fix the release script not publishing binary wheels. (#13850) 2022-09-21 09:43:08 +00:00
13855.bugfix Fix access token leak to logs from proxyagent (#13855) 2022-09-23 11:49:39 -05:00
13859.misc Raise issue if complement fails with latest deps (#13859) 2022-09-22 17:33:37 +01:00
13860.feature Add version flag for MSC3881 (#13860) 2022-09-21 18:18:44 +02:00
13863.bugfix Fix have_seen_event cache not being invalidated (#13863) 2022-09-27 15:55:43 -05:00
13867.misc Dockerfile for tests: align comments with current behavior (#13867) 2022-09-27 15:55:43 +02:00
13870.doc Fix the cross-link from register admin API to config docs. (#13870) 2022-09-22 09:11:50 -04:00
13872.bugfix Faster room joins: Fix spurious error when joining a room (#13872) 2022-09-27 11:17:23 +01:00
13873.misc Snapshot schema 72 (#13873) 2022-09-26 18:28:32 +01:00
13874.misc Send device list updates out to servers in partially joined rooms (#13874) 2022-09-23 13:44:03 +01:00
13876.misc Add comments to the Prometheus recording rules to make it clear which set of rules you need for Grafana or Prometheus Console. (#13876) 2022-09-23 11:46:45 +01:00
13885.misc Handle the case of remote users leaving a partial join room for device lists (#13885) 2022-09-27 13:01:08 +01:00
13888.misc Faster room joins: Avoid blocking /keys/changes (#13888) 2022-09-23 17:55:15 +01:00
13889.misc Update Cargo.lock file. (#13889) 2022-09-23 11:59:39 -04:00
13892.feature Add new columns tracking when we partial-joined (#13892) 2022-09-27 17:26:35 +01:00
13893.feature Improve tests for get_unread_push_actions_for_user_in_range_*. (#13893) 2022-09-26 18:28:12 +00:00
13905.misc Fix mypy errors with latest canonicaljson (#13905) 2022-09-26 13:30:00 +01:00
13909.bugfix Correctly add Cargo.lock to sdsit (#13909) 2022-09-26 13:58:10 +00:00
13911.doc Update the manpage documentation for the hash_password script (#13911) 2022-09-26 18:18:41 +00:00
13914.misc Complement image: propagate SIGTERM to all workers (#13914) 2022-09-26 23:07:02 +01:00
13915.doc Emphasize the right reasons to use (room_id, event_id) in a schema (#13915) 2022-09-27 19:43:16 +00:00
13920.feature Support the stable dir parameter for /relations. (#13920) 2022-09-27 10:47:34 -04:00
13922.bugfix Prioritize outbound to-device over device list updates (#13922) 2022-09-27 15:17:41 +01:00