integrations-core icon indicating copy to clipboard operation
integrations-core copied to clipboard

PG: Add recovery prefetch metrics

Open bonnefoa opened this issue 8 months ago • 1 comments

What does this PR do?

Add Postgres recovery prefetch metrics.

Motivation

PG15 introduces asynchronous IO in the recovery process based on posix_fadvise (mostly using POSIX_FADV_WILLNEED). With this, pg_stat_recovery_prefetch was also introduced to provide visibility on how efficient prefetching is. Providing metrics will help to tune maintenance_io_concurrency parameter. For example, io_depth is saturated but the disk still had capacity so increasing maintenance_io_concurrency could help increase recovery throughput.

Review checklist (to be filled by reviewers)

  • [ ] Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • [ ] Add the qa/skip-qa label if the PR doesn't need to be tested during QA.
  • [ ] If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

bonnefoa avatar Jun 06 '25 15:06 bonnefoa

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 90.33%. Comparing base (fc06fa6) to head (f8cbef1). Report is 35 commits behind head on master.

Additional details and impacted files
Flag Coverage Δ
activemq ?
cassandra ?
confluent_platform ?
hive ?
hivemq ?
hudi ?
ignite ?
jboss_wildfly ?
kafka ?
postgres 93.10% <100.00%> (+3.54%) :arrow_up:
presto ?
solr ?
tomcat ?
weblogic ?

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

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

codecov[bot] avatar Jun 06 '25 15:06 codecov[bot]