Skip to content
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

fix: consumption metrics on restart #5323

Merged
merged 12 commits into from
Sep 16, 2023
Merged

Conversation

koivunej
Copy link
Member

@koivunej koivunej commented Sep 15, 2023

Fixes: #5206
Cc: #5175 (loggings, will be enhanced in follow-up)

Write collected metrics to disk to recover previously sent metrics on restart.

Recover the previously collected metrics during startup, send them over at right time

  • send cached synthetic size before actual is calculated
  • when last_record_lsn rolls back on startup
    • stay at last sent written_size metric
    • send written_size_delta_bytes metric as 0

Add test support: stateful verification of events in python tests.

@koivunej koivunej force-pushed the refactor_consumption_metrics_test_5 branch from 77cc4fe to 1579f69 Compare September 15, 2023 23:01
@koivunej koivunej marked this pull request as ready for review September 15, 2023 23:34
@koivunej koivunej requested review from a team as code owners September 15, 2023 23:34
@koivunej koivunej requested review from bojanserafimov and shanyp and removed request for a team September 15, 2023 23:34
@github-actions
Copy link

2484 tests run: 2362 passed, 0 failed, 122 skipped (full report)


Flaky tests (1)

Postgres 16

  • test_get_tenant_size_with_multiple_branches: debug

Code coverage (full report)

  • functions: 53.0% (7748 of 14613 functions)
  • lines: 81.1% (45257 of 55836 lines)

The comment gets automatically updated with the latest test results
875e219 at 2023-09-15T23:44:50.469Z :recycle:

@koivunej koivunej merged commit f902777 into main Sep 16, 2023
@koivunej koivunej deleted the refactor_consumption_metrics_test_5 branch September 16, 2023 08:24
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.

consumption_metrics: sending previously sent values on restart
2 participants