Skip to content

Refine and commit all temporary metrics from DanShaders:ton:more-metrics#2339

Open
avevad wants to merge 11 commits into
testnetfrom
more-metrics-new
Open

Refine and commit all temporary metrics from DanShaders:ton:more-metrics#2339
avevad wants to merge 11 commits into
testnetfrom
more-metrics-new

Conversation

@avevad

@avevad avevad commented Apr 28, 2026

Copy link
Copy Markdown
Contributor
Screenshot_20260428_192341

@avevad avevad self-assigned this Apr 28, 2026
@avevad avevad changed the base branch from master to testnet April 28, 2026 16:24
@github-actions

Copy link
Copy Markdown
  • validator/manager.cpp:3851: update_block_receive_stats() increments blocks_new_total again whenever a new receive type is observed after the block was already marked applied. That makes new_total count late observations rather than blocks, so a block applied first and then later seen via download/broadcast/candidate can be counted multiple times. This path should either update received_from_total_ for the late type or skip counter changes, but it should not increment new_total_ again.

Revert "Add block receive prometheus stats"

This reverts commit 6059bdc.
@avevad avevad force-pushed the more-metrics-new branch from 202e075 to f56dd27 Compare April 28, 2026 16:27
@github-actions

Copy link
Copy Markdown
  • validator/manager.cpp: new_block_broadcast records the broadcast source before ValidateBroadcast succeeds. Invalid broadcasts can poison first_received_from_total/received_from_total for a block that is later applied. Record the source only after co_await task succeeds.

  • validator/manager.cpp: new_total_ is incremented again for every new source observed after a block was already marked applied, even though the block was already counted in new_block_cont. This makes blocks_new_total count observations, not blocks, and late sources are not reflected in received_from_total_.

Revert "tl: generate id -> name map"

This reverts commit be26e91.
@github-actions

Copy link
Copy Markdown
  • validator/manager.cpp:3850: update_block_receive_stats() increments new_total_ for any new receive type observed after stats.applied is already true. A duplicate/late broadcast or candidate for an already-applied block will therefore increase the total block counter again without incrementing received_from_total_ or first_received_from_total_, skewing the metric denominator. Late events should either be ignored for the applied-block totals or update the per-source counters without re-counting the block.

@avevad avevad marked this pull request as draft April 28, 2026 17:25
@avevad avevad force-pushed the more-metrics-new branch from d2da2c7 to acf2ae8 Compare April 30, 2026 16:24
@avevad avevad marked this pull request as ready for review May 1, 2026 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants