[cp][aptos-release-v1.44] [consensus] Add pull loop duration and empty retry metrics#19464
Open
aptos-bot wants to merge 1 commit intoaptos-release-v1.44from
Open
[cp][aptos-release-v1.44] [consensus] Add pull loop duration and empty retry metrics#19464aptos-bot wants to merge 1 commit intoaptos-release-v1.44from
aptos-bot wants to merge 1 commit intoaptos-release-v1.44from
Conversation
* [consensus] Add pull loop duration and empty retry metrics The payload pull loop in proposal generation can silently add 30-300ms of latency when QS has no batches ready, but there are no metrics to confirm this. Add two new metrics to instrument the outer pull loop: - aptos_consensus_pull_loop_duration_seconds: full loop duration - aptos_consensus_pull_loop_empty_retries: count of 30ms empty retries per proposal Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * [consensus] Fix histogram buckets for pull loop metrics - PULL_LOOP_DURATION: add custom buckets at 30ms steps (matching NO_TXN_DELAY) up to 330ms, then coarser to 1s. Avoids the default Prometheus 250-500ms gap that would hide the 300ms poll ceiling. - PULL_LOOP_EMPTY_RETRIES: extend buckets to 35 retries to cover non-default configs (1000ms poll time = ~34 retries). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * [consensus] Fix formatting for histogram bucket vecs Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> (cherry picked from commit b35cd71)
4 tasks
danielxiangzl
approved these changes
Apr 15, 2026
grao1991
approved these changes
Apr 15, 2026
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Contributor
✅ Forge suite
|
Contributor
✅ Forge suite
|
This comment has been minimized.
This comment has been minimized.
Contributor
✅ Forge suite
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Backport
This will backport the following commits from
maintoaptos-release-v1.44:Questions ?
Please refer to the Backport tool documentation
Note
Low Risk
Low risk: adds consensus/QuorumStore observability only, with minimal logic change (tracking elapsed time and empty poll retries). Main risk is minor metric-cardinality/bucketing overhead or misleading interpretation if the loop semantics change.
Overview
Adds two new consensus metrics:
aptos_consensus_pull_loop_duration_seconds(custom-bucketed histogram for end-to-end pull-loop duration including retries) andaptos_consensus_pull_loop_empty_retries(histogram for how many empty polls occurred).In
QuorumStoreClient::pull, tracksempty_retries, records both histograms after the loop completes, and enriches the debug log withempty_retrieswhile reusing the computedpull_duration.Reviewed by Cursor Bugbot for commit 83d1dce. Bugbot is set up for automated code reviews on this repo. Configure here.