|
From: Hiren P. <hir...@gm...> - 2009-06-11 07:56:12
|
Ton Voon wrote: > >> I can't help but think that something like this could have been quite >> easily resolved with a round-robin scheduling queue, where items >> requested >> to be queued would simply get inserted within 5 seconds of the >> requested >> time where there are the most free slots. The prng idea will probably >> work just as well though, and I'm fairly certain you could just use >> >> next_time = service->check_interval - 7 + (*service->description & >> 0xf); >> >> to get a distribution almost equally good without having to bother >> about the PRNG-business. This would yield 7 seconds +-, which is >> probably good enough. > > I notice that rand() is already used elsewhere in nagios, so I will go > with that instead. > I haven't seen this being an issue with our setup, but if there's a way to simulate it and you'd like me to test this for you, I'd be glad to. |