Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

caching on have_seen_event is somewhat broken #13865

@richvdh

Description

@richvdh

As discovered in #13863 (comment) and discussed in #synapse-dev. Part of #13856

The cache on have_seen_event uses a TreeCache, which means the cache is structured as {room_id: {event_id: result}}. However, _have_seen_events_dict tries to use it with @cachedList, which stores entries as {(room_id, event_id): result}. As a result, caching is inefficient, and cache invalidation is unreliable.

Metadata

Metadata

Assignees

Labels

A-PerformancePerformance, both client-facing and admin-facingO-OccasionalAffects or can be seen by some users regularly or most users rarelyS-TolerableMinor significance, cosmetic issues, low or no impact to users.T-DefectBugs, crashes, hangs, security vulnerabilities, or other reported issues.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions