Categories
WordPress

Bradycardia & Cardiac Arrest for WordPress 3.6

Bradycardia is the resting heart rate of under 60 beats per minute….
Wikipedia

WordPress HeartbeatA new feature in WordPress 3.6 is an upgrade to the autosave functionality that’s been around for years. It’s called “Heartbeat” and it makes sure you have valid authentication credentials, aren’t working on the same post as other people, and more. The problem is that (as it is) it slows web pages down to a grinding halt.

Read the active discussion on WordPress.org about this feature – a lot of people are upset about the CPU load it adds.

Note: I don’t recommend doing these changes on every Admin page. Use sparingly.

Slow Down WordPress 3.6’s Racing Heartbeat

Here’s how to slow down the heartbeat from once every 15 seconds (the default) to once every minute (the max allowed by WordPress):


add_filter( ‘heartbeat_settings’, ‘my_heartbeat_settings’ );
function my_heartbeat_settings($settings = array()) {
$settings[‘interval’] = 60;
return $settings;
}

Cardiac Arrest: Stop the WordPress Heartbeat Altogether

Add this line to your plugin or theme’s `functions.php` file to kill the heartbeat:
“remove_action( ‘admin_init’, ‘wp_auth_check_load’ );“

I hope this helps your own racing heart that’s been troubled by the heartbeat problem 🙂

Image by halfblog.net

By Zack Katz

Zack Katz is the founder of GravityKit and TrustedLogin. He lives in Leverett, Massachusetts with his wife Juniper.

6 replies on “Bradycardia & Cardiac Arrest for WordPress 3.6”

Thanks for this!

If one were a conspiracy theorist… one could well imagine a WP meeting with hosting service providers, the latter convincing WP to up resource usage so as to enable an up-sell to higher level (read: more expensive) of service. 🙂

But that would be evil.

Yeah, people on that Trac thread are suggesting hosts may block the heartbeat, making it a big problem.

I see where it would be good to have something like this, but I don’t see why it is so heavy! How does Google handle this, for instance?

Comments are closed.