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

Configuration reload needed - what it should be... #96

Open
mohierf opened this issue Jul 20, 2017 · 1 comment
Open

Configuration reload needed - what it should be... #96

mohierf opened this issue Jul 20, 2017 · 1 comment

Comments

@mohierf
Copy link
Contributor

mohierf commented Jul 20, 2017

As of now, the arbiter module declares that the configuration need to be reloaded because some items were modified in the backend. It periodically checks if some modifications occured and then sends a SIGHUP to the arbiter.

The list of concerned items: 'realm', 'command', 'timeperiod', 'usergroup', 'user', 'hostgroup', 'host', 'hostdependency', 'hostescalation', 'servicegroup', 'service', 'servicedependency', 'serviceescalation'

The main problem is that some modifications in some properties of those items do not concern the monitoring. Let's say that you changed the Notes property of a user ... it is obivously not necessary to make the arbiter reload and dispatch the monitoring configuration!

What should be done?

  1. currently it is not possible to disable the configuration reload needed check.

  2. allowing to force the configuration reload thanks to a global parameter would allow to control when the reload will happen

  3. defining a property in the items that indicates if the reload is needed would be of interest

How should it operate?

Allowing to set the verify_modification parameter to a 0 value would allow to disable the automatic configuration reload check. If some users wish to control by their own the Alignak configuration change restart.

As of now, we have an alignak endpoint in the backend that is updated with the update_program_status brok raised by the scheduler. The items stored in this endpoint are the configuration and state of all the Alignak instances using the backend.

We should store an information about the configuration reload in those items. A configuration_check_enabled property will allow to enable / disable the automatic configuration reload mechanism. A configuration_reload_needed will inform about the need to reload the configuration.

The configuration_reload_needed property should be updated with a more subtle algorithm than the one currenlty used. As of now, we should set this property if any items in the current list has been updated, but in the future we should have a more fine-grained solution.

The proposed algorithm:

  • have a list of interesting items categories
  • check the count of each items categories, if changed, set configuration_reload_needed
  • check the _updated property of each item, if some changed, set configuration_reload_needed

Note that the last check is the one that is currently executed...

@mohierf
Copy link
Contributor Author

mohierf commented Jul 20, 2017

An idea to improve the algorithm would be as: Alignak-monitoring-contrib/alignak-backend#389

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

No branches or pull requests

1 participant