-
Notifications
You must be signed in to change notification settings - Fork 814
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
[powerdns_recursor] add integration #2490
Conversation
5d25218
to
25c0263
Compare
@AntoCard and @janeczku I restricted the metrics collected to the ones you advised, and used rates to collect the counter metrics: I think it's more useful to know the questions rate than the number of questions, please let me know if I'm wrong. @janeczku I think the metrics exposed by PowerDNS are too incomplete to be useful if converted to a histogram, so I also submitted them as rates. @AntoCard Thanks again for your initial PR ! |
except Exception: | ||
self.service_check(self.SERVICE_CHECK_NAME, AgentCheck.CRITICAL, | ||
tags=service_check_tags) | ||
raise |
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.
Would we want to raise a custom error here rather than just the exception that was thrown by requests?
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.
It could be nice, but since I have no idea what a non-2xx status means for PowerDNS, it wouldn't provide much more information than the default requests
error.
So for now I'm going to keep it this way, if someone has an issue with the check, we'll update it to precise the error message.
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.
Reasonable.
I added a single note, but otherwise I think this looks fine. |
25c0263
to
0781d38
Compare
This check now only collects metrics deemed useful. It also sends a service check. The configuration file is cleaned, and a few comments are added for documentation purposes.
Build from source (:broken_heart:) and then test.
0781d38
to
2298a51
Compare
Thanks for the review @gmmeyer ! I'll wait for the 💚 CI before merging. |
This PR supersedes #2108.
It adds a service check, restrict metrics being collected, and adds integration tests.