-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Add configuration agent health event for Postgres #21347
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
base: master
Are you sure you want to change the base?
Add configuration agent health event for Postgres #21347
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files🚀 New features to boost your workflow:
|
…530-add-agent-health-event-for-postgres-config-validation-2
@@ -284,6 +289,7 @@ files: | |||
example: true | |||
- name: locks_idle_in_transaction | |||
description: Configure collection of idle in transaction lock age metrics | |||
hidden: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why hidden?
for m in custom_metrics: | ||
for param in required_parameters: | ||
if param not in m: | ||
raise ConfigurationError('Missing {} parameter in custom metric'.format(param)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we be more descriptive into which custom metric has a missing parameter
cap_mtype = mtype.upper() | ||
if cap_mtype not in ('RATE', 'GAUGE', 'MONOTONIC'): | ||
raise ConfigurationError( | ||
'Collector method {} is not known. Known methods are RATE, GAUGE, MONOTONIC'.format(cap_mtype) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similarly here. I think it would be helpful to know which custom metric has an invalid type
|
||
m['metrics'][ref][1] = METRIC_TYPES[cap_mtype] | ||
except Exception as e: | ||
raise Exception('Error processing custom metric `{}`: {}'.format(m, e)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is almost what I was looking for above, but it looks like m
here is the full dict of metrics? This looks wrong
What does this PR do?
InstanceConfg
modelMotivation
Review checklist (to be filled by reviewers)
qa/skip-qa
label if the PR doesn't need to be tested during QA.backport/<branch-name>
label to the PR and it will automatically open a backport PR once this one is merged