summary refs log tree commit diff
path: root/docs
diff options
context:
space:
mode:
authorNick Mills-Barrett <nick@beeper.com>2024-04-12 09:28:44 +0100
committerGitHub <noreply@github.com>2024-04-12 09:28:44 +0100
commitfe4719a2683dcd0d9c9deb606a1895d222c1b001 (patch)
treeb3b6373ecf6efa33db213ac522a774989c1c0e0c /docs
parentFix mypy on latest Twisted release (#17036) (diff)
downloadsynapse-fe4719a2683dcd0d9c9deb606a1895d222c1b001.tar.xz
Use receipts `event_stream_ordering` instead of joins (#17032)
Resurrecting https://github.com/matrix-org/synapse/pull/13918.

This should reduce IOPs incurred by joining to the events table to
lookup stream ordering, which happens in many receipt handling code
paths. Like the previous PR I believe sufficient time has passed between
the original migration in DB schema 72 and now to merge this as-is. It's
highly unlikely that both the migration is still ongoing AND (active)
users still have any receipts prior to that date.

In the unlikely event there is a receipt without a populated
`event_stream_ordering` synapse will behave just as it does now when
receipts exist for events that don't (yet): for push action calculation
the receipts are just ignored.

I've removed the validation on event IDs as this is already covered
here:

https://github.com/element-hq/synapse/blob/59ceabcb9798793cd4312fdbcced4e612aeda84d/synapse/handlers/receipts.py#L189-L192
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions