Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initialise earlier on init to fix issues with ALTERNATE_WP_CRON #24

Merged
merged 10 commits into from Apr 23, 2015

Conversation

Projects
None yet
1 participant
@thenbrent
Copy link
Member

commented Jul 10, 2014

When ALTERNATE_WP_CRON is defined, WordPress runs wp_cron() too early - bug report here.

As a result, the 'action_scheduler_run_queue' hook is triggered before ActionScheduler_QueueRunner::init() has run, because it is hooked to 'init' with the default priority in ActionScheduler::init().

This commit moves the initialisation to a higher priority to make sure everything it setup and attached to 'action_scheduler_run_queue' before wp_cron() runs.

thenbrent and others added some commits Jul 9, 2014

Initialise earlier on init
When `ALTERNATE_WP_CRON` is defined, WordPress runs `wp_cron()` too early [bug report here](https://core.trac.wordpress.org/ticket/24160).

As a result, the `'action_scheduler_run_queue'` hook is triggered before `ActionScheduler_QueueRunner::init()`
has run, because it is hooked to `'init'` with the default priority in `ActionScheduler::init()`.
Johan Eenfeldt
Bugfix: flush cache if not using external cache or if filter is modified
Currently it will ONLY flush caches if using an external cache and if the filter is not modified, the inverse of what we want.
Fetch the actions within the try/catch block
To ensure that any catchable exceptions that occur while fetching the
action do not block the entire queue (like invalid JSON in `post_content`).

Fixes #26.
Trigger before execute hook before fetching action
To ensure any catchable fatal errors in fetching the action, like that
reported in #26 are handled by ActionScheduler_FatalErrorMonitor (which
only attaches itself on the `'action_scheduler_before_execute'` hook.

Part of #26
Merge pull request #28 from thenbrent/hide_log_from_counts
Do not include log entries in comment counts
Merge pull request #25 from johanee/master
Bugfix: flush cache if not using external cache or if filter is modified
Update build status image
To link to /prospress/ org repo
Update build status image
For real this time
Merge pull request #27 from thenbrent/fix-args-exceptions
Catch fatal errors when fetching action in queue

@thenbrent thenbrent merged commit 96d25fb into Prospress:master Apr 23, 2015

1 check was pending

continuous-integration/travis-ci/pr The Travis CI build is in progress
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.