Jump to content

Set LazyCron to operate at specified times


MarkE
 Share

Recommended Posts

LazyCron operates on an elapsed time interval, but you may want it to operate at specified times.

Assuming your website is going to be visited sufficiently frequently (either by real users or by a Cron job), you can do this by editing the file /assets/cache/LazyCron.cache. This file contains 21 timestamps – one for each of the LazyCron specified intervals (e.g. “everyMinute”). The timestamp denotes when that interval was last triggered. To make the trigger happen at the required time, change the timestamp in the matching row to be when the previous trigger should have occurred.

To make this easier, I have done an Excel spreadsheet (“Lazycron_fill.xlsx”) to simplify the process – just enter the required benchmark timings and copy the result into the LazyCron.cache file.

Lazycron_fill.xlsx

  • Like 2
Link to comment
Share on other sites

  • 11 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...