Repository navigation
fix(envoy-client): keep the ping silence deadline bounded across reconnects - #5843
Conversation
|
Stack for rivet-dev/rivet Current stack:
Dependencies: Get stack: change wpskpplp |
|
Review: keep the ping silence deadline bounded across reconnects The design is sound. A monotonic Possible issues
Minor
No security concerns. Style matches CLAUDE.md. |
| pub fn connection_installed(&self, now: Instant) { | ||
| let mut state = self.0.lock(); | ||
| state.connection_installed_at = Some(now); |
There was a problem hiding this comment.
🔴 High · Preserve command-proven liveness across reconnects
When a connection is claimed by commands before its first ping, commands_received() proves that the engine refreshed its persisted liveness timestamp, but that evidence is represented only by connection_claimed. The next connection_installed() overwrites the install time and clears the flag, while last_ping is still None, so baseline() jumps forward to the replacement connection's install time. If that replacement never gets claimed, the engine continues counting from the previous claim and can declare/move the actors before this client stops them. Retain the prior claimed baseline (the prior install time when no ping exists) across installs, and replace it only after the new connection is proven claimed; add the sequence install -> commands -> reconnect -> no commands/ping to the liveness tests.
baa6a32 to
86507ea
Compare
831507a to
4ef21a9
Compare
86507ea to
57602c5
Compare
No description provided.