Intervals should be staggered

Bug #1788518 reported by Ryan Finnie on 2018-08-22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Landscape Client

Bug Description

The various intervals appear to be statically determined from program start. As a practical example, a rebooted VM host with a large number of guests means all the guests start landscape-client at about the same time. Then every 30 minutes, package-monitor runs (which is a rather heavy operation). Multiply by a hundred or so and you've got a large flood on the host.

When the client starts up, it would be good to have the initial schedule for each timer be ((interval / 2) + random(interval)), so the collective load is spread out over the entire interval.

Tags: is Edit Tag help
Changed in landscape-client:
importance: Undecided → High
tags: added: is
Joel Sing (jsing) wrote :

In addition to (or instead of) spreading the initial schedule, it would be beneficial to +/- a random percentage (e.g. between -10% and +10%) to the next interval on each run. This means that instead of running at hard intervals, the runs become skewed but remain at the given interval on average. This avoids synchronisation and consistent load spikes if the initial offset results in it matching another fixed processing schedule (e.g. from a cronjob). The same applies with load distribution on the server side (if applicable).

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers