Repository navigation
Add hedge-trigger, final-outcome, attempted-payload and excluded-leader metrics #87
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
Merged
Merged
Changes from 1 commit
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
bb312b1
Add hedge-trigger, produce-failure, and agent-pool churn metrics
koloss2001 16669d5
exclude caller cancellation from final outcomes
koloss2001 ed18375
track write timeouts in final outcomes
koloss2001 1d7d5c1
Merge origin/main into koloss2001/hedge-trigger-instrumentation
koloss2001 89da2f7
Classify hedge triggers and final outcomes from the actual decision
koloss2001 00dd6b5
Assert final outcomes on hedger race paths and cover live agent-pool …
koloss2001 b880d9f
Add per-trigger hedge win counter
koloss2001 6b3fd94
Replace leader_dropped_total with an excluded_leaders gauge
koloss2001 d109506
Count attempted primary and hedge payload (records and compressed bytes)
koloss2001 f4a614c
Count hedge wins in the owning race and fix final-outcome classificat…
koloss2001 246d707
renamed tests
koloss2001 b88a842
Settle final-outcome reason once the primary's result is known and de…
koloss2001 21f50fd
Rename the failure-reason counter to produce_requests_failed_total an…
koloss2001 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
diffAgentMembershipassumes sorted, unique input.refreshsortsnewAgentsbut doesn't dedupe it. If a Metadata response ever lists a NodeID twice,[5,5]followed by[5]counts oneremovedwith no real membership change, which inflatesagents_changed_total.diffRemovedAgentsis unaffected because it goes throughagentSet. Probably rare in practice, but aslices.Compactafter the sort would make the documented precondition true. (Or derive the counts from the same set-based diffrefreshalready does.)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.
Fixed. refresh now deduplicates NodeIDs after sorting. It was worse than described: the pool itself held the duplicate and membership_changed was also counted. Added a test that duplicates a broker in the Metadata response.
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.
I'm reverting this. A correct Metadata response contains one entry per NodeID, and a duplicate is treated as malformed, so the sorted list already satisfies diffAgentMembership. Compacting also changes fallback routing for a malformed response (
hash % len(agents)and the secondary walk), which this PR otherwise doesn't touch. I've removed the slices.Compact call and its test.