Re: [PATCH 2/6] maintenance: use random minute in launchctl scheduler
- From
Taylor Blau <me@ttaylorr.com>
- Date
- Aug 7, 2023, 21:23 UTC
- Message-ID
- <ZNFgttgDTVr4sr6I@nand.local>
- In-Reply-To
- <babf62ec6d5181c65dd4b653ba9ae24e62a88830.1691434300.git.gitgitgadget@gmail.com>
On Mon, Aug 07, 2023 at 06:51:36PM +0000, Derrick Stolee via GitGitGadget wrote:
Show 11 quoted lines
> From: Derrick Stolee <derrickstolee@github.com> > > The get_random_minute() method was created to allow maintenance > schedules to be fixed to a random minute of the hour. This randomness is > only intended to spread out the load from a number of clients, but each > client should have an hour between each maintenance cycle. > > Use get_random_minute() when constructing the schedules for launchctl. > > The format already includes a 'Minute' key which is modified from 0 to > the random minute.
All looks good. I was wondering if this is something that we'd want to allow users to opt out of, but I think that the built-in schedules are sufficiently vague that we can afford to have a fudge factor on the exact minute.
Thanks, Taylor