Hi Ron,
WordPress only executes wp-cron.php
when it needs to. On every page load, WordPress checks to see if there are any cron jobs that need to run (this is quite a cheap operation) and if so it calls wp-cron.php
asynchronously (which is potentially an expensive operation) which in turns runs any cron jobs that need running.
If wp-cron.php
is being executed on every page load then there’s something wrong with cron on your site. You can use WP Crontrol to see what jobs are scheduled.
If you add define('DISABLE_WP_CRON', true);
to your config file you’ll need to manually set up a server cron to call that file at an appropriate interval. WP Crontrol only shows you what jobs are scheduled.
Thanks for replying and sorry for the almost duplicate question. I immediately fell in love with this plugin by the way since I have numerous background functions to prepare meta data and cleanup garbage that I’ve been triggering off of periodic user or admin actions. It is nice to have a ui to keep track of them (and actually change them or execute manually ). Thanks for doing this.
I did not realize there were two parts to the built in wp-cron.
Now that you enlightened me that it won’t do any work (other than a quick check) unless it has an event scheduled, it looks like there is no significant advantage in disabling the built in wp-cron.
It would only take a few milliseconds for wp to check a few cached db records (the scheduled tasks).
From your experience, is it ever worth disabling?