-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add advanced pub/sub last sample miss detection #1701
base: main
Are you sure you want to change the base?
Add advanced pub/sub last sample miss detection #1701
Conversation
// TODO: add state to avoid sending multiple queries for the same heartbeat if its periodicity is higher than the query response time | ||
|
||
// check that it's not an old sn or a pending sample's sn | ||
if (state.last_delivered.is_none() | ||
|| state.last_delivered.is_some_and(|sn| heartbeat_sn > sn)) | ||
&& !state.pending_samples.contains_key(&heartbeat_sn) | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This TODO could be covered by not sending a query unless there are no pending queries (i.e no pending queries from heartbeat, periodic queries, or miss detection queries). Does that sound right @OlivierHecart ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hypothetically speaking, doing so might risk that (in some potential high-load cases) heartbeats would get denied by other querying mechanisms and never result in a heartbeat query...
Closes #1657