summary refs log tree commit diff
path: root/sytest-blacklist
diff options
context:
space:
mode:
authorJonathan de Jong <jonathan@automatia.nl>2021-02-24 14:57:00 +0100
committerGitHub <noreply@github.com>2021-02-24 13:57:00 +0000
commitf5c93fc9931e4029bbd8000f398b6f39d67a8c46 (patch)
tree537d1714534957ca65bdfc755ad4485656908166 /sytest-blacklist
parentClean up `ShardedWorkerHandlingConfig` (#9466) (diff)
downloadsynapse-f5c93fc9931e4029bbd8000f398b6f39d67a8c46.tar.xz
Fix #8518 (sync requests being cached wrongly on timeout) (#9358)
This fixes #8518 by adding a conditional check on `SyncResult` in a function when `prev_stream_token == current_stream_token`, as a sanity check. In `CachedResponse.set.<remove>()`, the result is immediately popped from the cache if the conditional function returns "false".

This prevents the caching of a timed-out `SyncResult` (that has `next_key` as the stream key that produced that `SyncResult`). The cache is prevented from returning a `SyncResult` that makes the client request the same stream key over and over again, effectively making it stuck in a loop of requesting and getting a response immediately for as long as the cache keeps those values.

Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>
Diffstat (limited to 'sytest-blacklist')
0 files changed, 0 insertions, 0 deletions