Error Triage Hub (9)
Synapse Worker Mode IPC & Redis Replication Lag
Misconfigured Redis replication ports or missing instance_map routing causes Synapse workers to fall behind the main writer stream position.
Sync Lag: 1.5-12s stale timelines | Cause: Redis / stream_writers
How Main Process Event Persistence Propagates Across Workers
In worker mode, event_persister and federation_sender processes subscribe to stream positions over Redis pub/sub and query the main process over HTTP replication endpoints. If Redis is bound improperly or nginx routes /_matrix/client/v3/sync to a saturated worker, messages appear seconds late.
Checking Replication RTT and Worker Health Metrics
Inspect synapse_replication_tcp_client_connected and event_stream_position lag across worker Prometheus targets. Keeping Redis on loopback with zero disk AOF fsync overhead eliminates replication jitter.
Measured Thresholds & Configuration
| Worker IPC Setting | Replication Lag | Recommended Topology |
|---|---|---|
| Redis AOF always + 1 worker | 400 - 3,000 ms spikes | Avoid fsync=always on Redis |
| Redis no-save + local loopback | < 15 ms propagation | Dedicated federation_sender + sync |
| Single-Binary Continuwuity Rust | 0 ms (in-process Tokio) | Under 300 users (no workers needed) |