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 support for Netbox webhooks #131

Open
33Fraise33 opened this issue Aug 14, 2023 · 2 comments
Open

Add support for Netbox webhooks #131

33Fraise33 opened this issue Aug 14, 2023 · 2 comments
Labels
question Further information is requested wontfix This will not be worked on

Comments

@33Fraise33
Copy link

Hello,

Currently the sd plugin creates an api call for each job following the configured refresh_interval under the http_sd_config in prometheus (http_sd_config).

This might create some load if you have quite some jobs for different device types running over different prometheus instances.
It would be nice to let this plugin do the initial scrape on prometheus request and subscribe to changes through Netbox webhooks and dynamically update the sd result for prometheus based on the received changes from the Netbox webhook.

This creates a kind of cache for netbox limiting the amount of database calls happening.

I am unsure how in scope this is but it would be nice to have it as a feature that can be enabled on request (giving both options between in memory cache or not)

@FlxPeters
Copy link
Owner

I don't see the demand for this kind of complexity. At least my Netbox deployments doesn't have any performance issues when running the plugin. Also there should be a caching on the database.

Introducing a cache is nothing I want to do without a need.

I will let this issue open to catch some others feedback, but for now this won't be implemented.

@FlxPeters FlxPeters added question Further information is requested wontfix This will not be worked on labels Aug 22, 2023
@llamafilm
Copy link
Contributor

llamafilm commented Jan 10, 2024

I’m also seeing performance problems, see #156. But I don’t know if adding a cache is the right approach. I’m hoping the database queries can be optimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants