Files
synapse/changelog.d/rust-persist-batch.misc
T
Erik JohnstonandClaude Opus 5.5 1452faf192 Recalculate a room's current state in Rust at rust_event_persistence: full
`_update_current_state`, the queue's `_UpdateCurrentStateTask`, becomes
one call to `Persister.update_current_state`:

- `calculate_current_state` reads the room's forward extremities (its
  state DAG extremities in an MSC4242 room) and takes the state of
  their one state group, or resolves several, after checking the groups
  still exist and putting off their deletion, as `resolve_state_groups`
  does.
- The delta from the current state and the sliding sync table changes
  are computed as for a chunk, with no events.
- If anything changed, one stream ID is taken from the events stream,
  as `get_next` does, and `_update_current_state_txn` runs in Rust.
  Python applies the effects, which finishes the ID.

A room on state resolution v1 whose extremities need resolving is handed
back, and Python recalculates its state as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LXMkcZVkcZhi21augBff4a
2026-10-18 10:35:53 +00:00

2 lines
148 B
Plaintext

Persist each queued batch of events in Rust, and recalculate a room's current state there, at `experimental_features.rust_event_persistence: full`.