Rework postgres check to split server metrics from db metrics #1073
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Rework postgres check to split server metrics from db metrics
For postgres some metrics are collected only once per postgres server
(even if the user is monitoring multiple databases on the server from
one agent).
This rework is needed so the postgres check work properly on agent6
where check instances don't share the same check instance.
The check detect the version of the agent running by trying to import
datadog_agent
and only apply instance tags toCOMMON_METRICS
,NEWER_92_METRICS
,DATABASE_SIZE_METRICS
,COMMON_BGW_METRICS
,NEWER_91_BGW_METRICS
andCOMMON_ARCHIVER_METRICS
if its running on agent5.Versioning
manifest.json
datadog_checks/{integration}/__init__.py
CHANGELOG.md
. Please useUnreleased
as the date in the titlefor the new section.