Use drupal_cron_run() (fixes FeedAPI compatibility problem and multiple simultaneous runs)
pwolanin - February 14, 2007 - 18:00
| Project: | Poormanscron |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Description
In 5.x and HEAD, you should be able to call this function and cut out a lot of your code: http://api.drupal.org/api/5/function/drupal_cron_run

#1
Testing would be much appreciated.
#2
quick skim looks good
#3
Subscribing.
#4
http://drupal.org/cvs?commit=113162
#5
Oops, this actually needs to be patched into 5.x-1.x-dev.
#6
#1 also needs to be applied to HEAD.
[update]
Also note that you currently need to use 6.x-1.x-dev to get this fix, it's not included in 6.x-1.0.
#7
Another note: this patch removes the ability of poormanscron to log the progress of cron runs (though it doesn't get rid of the static variable that controls this..). There is also an open core issue for this: #131536: Make cron watchdog more granular and informative.
Also changing title to reflect the fact that this patch enables poormanscron to work with FeedAPI, since using http://api.drupal.org/api/5/function/drupal_cron_run means that the cron_semaphore flag will automatically be set during the cron run.
#8
#9
It's not clear to me from the above -- has 6.x-1.x-dev been patched as well?
I'm troubled by the notorious multiple-mail Simplenews problem #361071: Multiple emails revisited - 50% too many ...
#10
+1 here.... thanks
#11
+1 here too
#12
Backported to the 5.x branch and new releases created with this for both branches.
#13
Automatically closed -- issue fixed for 2 weeks with no activity.