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

prometheus.exporter.snmp to support multiple config files #916

Open
ptodev opened this issue May 23, 2024 · 3 comments · May be fixed by #967
Open

prometheus.exporter.snmp to support multiple config files #916

ptodev opened this issue May 23, 2024 · 3 comments · May be fixed by #967
Assignees
Labels
enhancement New feature or request v2.0-breaking-change Breaking changes that we intend to do for v2.0 major release

Comments

@ptodev
Copy link
Contributor

ptodev commented May 23, 2024

Request

The config_file (and maybe config) options can be changed from string to list(string), so that users can specify more than one config file. This is a feature which was added upstream some time ago.

This was requested by @bastischubert

Use case

It could be helpful to split out a config file into multiple files.

@ptodev ptodev added enhancement New feature or request v2.0-breaking-change Breaking changes that we intend to do for v2.0 major release labels May 23, 2024
@rfratto
Copy link
Member

rfratto commented May 23, 2024

Is there a way that this can be done without a breaking change, like a new config_files argument that becomes mutually exclusive with the config_file argument?

@hainenber
Copy link
Contributor

That's also more intuitive, imo. From user perspective, it'd be pretty weird passing a list of SNMP config files to config_file rather config_files

Or maybe we can mark config_file as deprecated and enforce people passing single-entry list of SNMP config file to config_files? 🤔

@ptodev
Copy link
Contributor Author

ptodev commented May 30, 2024

Is there a way that this can be done without a breaking change, like a new config_files argument that becomes mutually exclusive with the config_file argument?

I would be happy with that. I also think we should document the config_file argument as "deprecated", as @hainenber suggested. Having both arguments side by side will give people time to migrate prior to 2.0.

From user perspective, it'd be pretty weird passing a list of SNMP config files to config_file rather config_files

True! It was sort of implied in the original issue above, but I didn't mention it. Thanks for clearing it. up :)

Btw I don't think this is super high priority, because in theory config_file accepts a glob pattern. So even with the current config it should be possible for folks to use multiple files. I haven't tested it though. Hopefully we can use the integration tests in #954 for this purpose in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request v2.0-breaking-change Breaking changes that we intend to do for v2.0 major release
Projects
None yet
3 participants