shinken-monitoring / mod-livestatus

Shinken module for presenting data with a MK/Livestatus comptabile interface

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fix interval_length column

smlacombe opened this issue · comments

In the file mapping.py at line 3577, the interval_length column has to be repaired. There are a few other columns that do a calculation using the interval_length. The code is quite generic. I've watched the code but I don't find where the configuration properties are interfaced between the broker and the livestatus module. Does somebody can give me a clue?

Global conf parameter are exported "one by one" (maybe we can change this?)
by the schedulers at scheduler.py::get_program_status_broks()

On Tue, Jul 30, 2013 at 9:51 PM, Samuel Milette-Lacombe <
notifications@github.com> wrote:

In the file mapping.py at line 3577, the interval_length column has to be
repaired. There are a few other columns that do a calculation using the
interval_length. The code is quite generic. I've watched the code but I
don't find where the configuration properties are interfaced between the
broker and the livestatus module. Does somebody can give me a clue?


Reply to this email directly or view it on GitHubhttps://github.com//issues/1
.

Thanks for the clue, I've fixed the column. I've just add this item:: « "interval_length": self.conf.interval_length, » in the data dictionnary in get_program_status_broks(). Other columns seem to solve itself in the same way.

I understand what you say for "one by one" exporting. It could be more dynamic indeed.
We could just separate the attributes from config object that we want exposed and then we could iterate on this attributes and append each one in the data dictionnary.

If we do this, we must make sure to keep the original name for each configuration properties already exposed to avoid having to modify a lot of files.

Export all is a better default than "export one after an other if a user
ask it" :)

On Tue, Jul 30, 2013 at 10:35 PM, Samuel Milette-Lacombe <
notifications@github.com> wrote:

Thanks for the clue, I've fixed the column. I've just to add this item:: «
"interval_length": self.conf.interval_length, » in the data dictionnary in
get_program_status_broks(). Other columns seem to solve itself in the same
way. I understand what you say for "one by one" exporting, but why you want
to change this? May I have some explications.


Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-21820700
.