Skip to content

fix(flatkv): correct catchup metrics#3447

Open
blindchaser wants to merge 1 commit into
mainfrom
yiren/fix-metrics
Open

fix(flatkv): correct catchup metrics#3447
blindchaser wants to merge 1 commit into
mainfrom
yiren/fix-metrics

Conversation

@blindchaser
Copy link
Copy Markdown
Contributor

Describe your changes and provide context

  • avoid recording CurrentVersion from catchup so read-only historical loads do not pollute the write-mode height metric. Reset PendingWrites after each replayed WAL entry to mirror Commit behavior.

Testing performed to validate your change

…from catchup so read-only historical loads do not pollute the write-mode height metric. Reset PendingWrites after each replayed WAL entry to mirror Commit behavior.
@cursor
Copy link
Copy Markdown

cursor Bot commented May 15, 2026

PR Summary

Low Risk
Metrics-only changes in the WAL catchup path; no persistence or replay logic is modified, but observability values will change during catchup/replay.

Overview
Stops catchup from recording the CurrentVersion gauge so read-only historical loads don’t pollute the write-mode height metric.

After each replayed WAL entry, catchup now resets per-DB PendingWrites metrics to 0, mirroring the metric behavior of normal Commit after pending buffers are cleared.

Reviewed by Cursor Bugbot for commit 51f31aa. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 15, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedMay 15, 2026, 10:53 PM

@codecov
Copy link
Copy Markdown

codecov Bot commented May 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 59.29%. Comparing base (823a78d) to head (51f31aa).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #3447   +/-   ##
=======================================
  Coverage   59.29%   59.29%           
=======================================
  Files        2125     2125           
  Lines      175629   175632    +3     
=======================================
+ Hits       104144   104149    +5     
+ Misses      62404    62402    -2     
  Partials     9081     9081           
Flag Coverage Δ
sei-chain-pr 75.32% <100.00%> (?)
sei-db 70.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
sei-db/state_db/sc/flatkv/store_catchup.go 65.41% <100.00%> (+0.79%) ⬆️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant