Skip to content

fix parsing include databases #521

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

Merged
merged 2 commits into from
Apr 19, 2021

Conversation

pvanderlinden
Copy link
Contributor

The introduction of the include databases flag disables the auto discovery flag completely, this PR will fix that.

Signed-off-by: Paul van der Linden <[email protected]>
Copy link
Contributor

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems reasonable, LGTM.

@SuperQ
Copy link
Contributor

SuperQ commented Apr 17, 2021

Should we add some tests for this?

@pvanderlinden
Copy link
Contributor Author

It probably should have some tests. I haven't had the time yet to check how the testing works, or how to setup some databases (as the current tests don't do that just yet).

@pvanderlinden
Copy link
Contributor Author

@SuperQ Are there any documentation on how to run the integration tests locally?
Also I'm wondering how usefull the include functionality is? Doesn't that actually defeat the purpose of auto discover?

@SuperQ
Copy link
Contributor

SuperQ commented Apr 19, 2021

Sorry, I don't know about either question. I'm not an expert in PG nor this exporter's codebase. It's an adopted project, not something from the core Prometheus team.

Signed-off-by: Paul van der Linden <[email protected]>
@pvanderlinden
Copy link
Contributor Author

I have added a basic integration test for this, and basic instructions for running the tests. It might need improvement, but it solves the current bug and adds a very simple test for it.

Copy link
Contributor

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks! This is great.

@SuperQ SuperQ merged commit 677d38b into prometheus-community:master Apr 19, 2021
ritbl pushed a commit to heniek/postgres_exporter that referenced this pull request Mar 19, 2023
…to-discovery

fix parsing include databases
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants