[mrtg-developers] Fwd: Re: MRTG check scheduling while in daemon mode
Niall.oReilly+mrtg-dev at ucd.ie
Niall.oReilly+mrtg-dev at ucd.ie
Wed Oct 6 09:59:23 CEST 2010
On 06/10/10 00:20, Steve Shipway wrote:
> Such as this pseudocode (note that since the poll is done in a
> separate thread the actual processing is a little more complex)
It's already too complex! 8-)
Having to copy the consequences of success or failure to the
related targets is a symptom of a problem. The normalization
concept from database theory could be used to simplify things
here. If a device queue (instead of a target queue) were to
drive polling, data relating to the device woud not need to be
duplicated.
Setting up the device queue entries, each with its list of
attached targets, would be part of configuration processing.
The set of target data for each device could be processed
and stored in the same thread in conjunction with polling.
Alternatively, a second poll-free pass over the device queue,
not necessarily in the same thread, could take care of this.
Niall
More information about the mrtg-developers
mailing list