mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-05-18 00:10:19 -04:00
Cancel the processing of key query requests when they time out. (#13680)
This commit is contained in:
parent
c2fe48a6ff
commit
d3d9ca156e
18 changed files with 110 additions and 20 deletions
|
@ -55,6 +55,7 @@ from synapse.types import JsonDict, PersistedEventPosition, StateMap, get_domain
|
|||
from synapse.util.async_helpers import Linearizer
|
||||
from synapse.util.caches import intern_string
|
||||
from synapse.util.caches.descriptors import _CacheContext, cached, cachedList
|
||||
from synapse.util.cancellation import cancellable
|
||||
from synapse.util.iterutils import batch_iter
|
||||
from synapse.util.metrics import Measure
|
||||
|
||||
|
@ -770,6 +771,7 @@ class RoomMemberWorkerStore(EventsWorkerStore):
|
|||
_get_users_server_still_shares_room_with_txn,
|
||||
)
|
||||
|
||||
@cancellable
|
||||
async def get_rooms_for_user(
|
||||
self, user_id: str, on_invalidate: Optional[Callable[[], None]] = None
|
||||
) -> FrozenSet[str]:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue