[DBMON-3520] - add pg_stat_io metrics to postgres integration
What does this PR do?
Adds the following pg_stat_io metrics to the postgres integration. These will only be available un postgres 16+. For now we'll want to only expose these for DBM users.
- postgresql.io.evictions
- postgresql.io.extends
- postgresql.io.extend_time
- postgresql.io.fsyncs
- postgresql.io.fsync_time
- postgresql.io.hits
- postgresql.io.reads
- postgresql.io.read_time
- postgresql.io.writes
- postgresql.io.write_time
Each of these metrics will include the following tags: backend_type, context, object.
Motivation
IO stat metrics were a big blindspot in older postgres versions. Exposing these will allow users to have better visibility into where IO time is being spent.
Additional Notes
This is my first contribution to integrations-core / postgres integration so any comments on direction of these changes is appreciated!
Review checklist (to be filled by reviewers)
- [ ] Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
- [ ] Changelog entries must be created for modifications to shipped code
- [ ] Add the
qa/skip-qalabel 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
The validations job has failed; please review the Files changed tab for possible suggestions to resolve.
Test Results
16 files 16 suites 21m 40s :stopwatch: 288 tests 286 :white_check_mark: 2 :zzz: 0 :x: 2 312 runs 2 183 :white_check_mark: 129 :zzz: 0 :x:
Results for commit a2fe5ff6.
:recycle: This comment has been updated with latest results.
Codecov Report
Attention: Patch coverage is 91.30435% with 2 lines in your changes are missing coverage. Please review.
Project coverage is 85.16%. Comparing base (
2a6ec26) to head (b5ce4d1). Report is 38 commits behind head on master.
:exclamation: Current head b5ce4d1 differs from pull request most recent head a2fe5ff. Consider uploading reports for the commit a2fe5ff to get more accurate results
Additional details and impacted files
Flags with carried forward coverage won't be shown. Click here to find out more.