Skip to content
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

Add exclude[] parameter #3116

Merged
merged 1 commit into from
Sep 14, 2024
Merged

Conversation

siavashs
Copy link
Contributor

@siavashs siavashs commented Sep 9, 2024

This PR adds an exclude[] URL parameter to exclude specific enabled collectors.
Compared to collect[] parameter, the exclude[] parameter results in a filtered list which equals enabled collectors minus excluded ones.

@SuperQ
Copy link
Member

SuperQ commented Sep 11, 2024

I like it, thanks!

Minor nit, I think to follow our naming pattern, we should call this exclude[].

@siavashs siavashs marked this pull request as draft September 13, 2024 08:56
@siavashs siavashs changed the title Add discard[] parameter Add exclude[] parameter Sep 13, 2024
@siavashs siavashs marked this pull request as ready for review September 13, 2024 09:19
@siavashs
Copy link
Contributor Author

Thanks for the suggestion and fixing the logging @SuperQ
I rebased and updated the PR.

node_exporter.go Outdated Show resolved Hide resolved
node_exporter.go Outdated Show resolved Hide resolved
This PR adds a `exclude[]` URL parameter to exclude specific enabled collectors.
Compared to `collect[]` parameter, the `exclude[]` parameter results in a filtered list which equals enabled collectors minus excluded ones.

Signed-off-by: Siavash Safi <[email protected]>
Copy link
Member

@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.

Thanks!

@SuperQ SuperQ merged commit 7a97429 into prometheus:master Sep 14, 2024
7 checks passed
rongyi pushed a commit to ontology-tech/node_exporter that referenced this pull request Oct 17, 2024
This PR adds a `exclude[]` URL parameter to exclude specific enabled collectors.
Compared to `collect[]` parameter, the `exclude[]` parameter results in a filtered list which equals enabled collectors minus excluded ones.

Signed-off-by: Siavash Safi <[email protected]>
v-zhuravlev pushed a commit to grafana/node_exporter that referenced this pull request Nov 1, 2024
This PR adds a `exclude[]` URL parameter to exclude specific enabled collectors.
Compared to `collect[]` parameter, the `exclude[]` parameter results in a filtered list which equals enabled collectors minus excluded ones.

Signed-off-by: Siavash Safi <[email protected]>
Signed-off-by: Vitaly Zhuravlev <[email protected]>
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