Closed neilalexander closed 2 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 68.19%. Comparing base (
7a4ef24
) to head (2459fd2
). Report is 3 commits behind head on main.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
The internal NATS instance is definitely convenient but it does have one problem: its lifecycle is tied to the Dendrite process. That means if Dendrite panics or OOMs, it takes out NATS with it. I suspect this is sometimes contributing to what people see with stuck streams, as some operations or state might not be written to disk fully before it gets interrupted.
Using
SyncAlways
means that NATS will effectively useO_SYNC
and block writes on flushes, which should improve resiliency against this kind of failure considerably. It might affect performance a little but shouldn't be significant.Also updates NATS to 2.10.20 as there have been all sorts of fixes since 2.10.7, including better
SyncAlways
handling.Signed-off-by: Neil Alexander git@neilalexander.dev