Skip to content

Clear unused scheduled events in wp_options cron. - #115

Open
bi0xid wants to merge 1 commit into
disqus:masterfrom
bi0xid:master
Open

Clear unused scheduled events in wp_options cron.#115
bi0xid wants to merge 1 commit into
disqus:masterfrom
bi0xid:master

Conversation

@bi0xid

@bi0xid bi0xid commented Jul 16, 2016

Copy link
Copy Markdown

Clears unused scheduled events in wp_options cron before adding a new
scheduled event. Prevents server exhaustion and several problems when having heavy loads of information in wp_options cron.

Solves
https://disqus.com/home/channel/discussdisqus/discussion/channel-discuss
disqus/tons_of_dsq_sync_forum_entries_in_cron_row_wp_options_and_10x_ser
ver_loads/
Solves
https://wordpress.org/support/topic/high-server-load-and-dsq_sync_forum-
problem

Clears unused scheduled events in wp_options cron before adding a new
scheduled event.
Solves
https://disqus.com/home/channel/discussdisqus/discussion/channel-discuss
disqus/tons_of_dsq_sync_forum_entries_in_cron_row_wp_options_and_10x_ser
ver_loads/
Solves
https://wordpress.org/support/topic/high-server-load-and-dsq_sync_forum-
problem
@archon810

Copy link
Copy Markdown
Contributor

This will just continue clearing and postponing and never running the Disqus sync cron job on a busy server.

Comment thread disqus/disqus.php
}
} else {
wp_clear_scheduled_hook( 'dsq_sync_forum' );
$ts = time() + 300;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this may not work. Rather ba0a89e is better solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants