[wp-trac] [WordPress Trac] #23216: Create "WP Heartbeat" API
WordPress Trac
noreply at wordpress.org
Mon Apr 15 21:19:13 UTC 2013
#23216: Create "WP Heartbeat" API
----------------------------+------------------
Reporter: azaozz | Owner:
Type: task (blessed) | Status: new
Priority: normal | Milestone: 3.6
Component: Administration | Version:
Severity: normal | Resolution:
Keywords: autosave-redo |
----------------------------+------------------
Comment (by DavidAnderson):
Well, here's a crude estimation. On a 4-core Intel Xeon X3360 @ 2.83GHz
webserver that I use, loading the WordPress dashboard (the server is using
PHP via CGI) uses 0.3 seconds of CPU time (not wall time). On my laptop
it's about double that. I've seen plenty of cheap VPSes that are
comparable to my laptop.
Once very 15 seconds = one CPU can serve 50 WP admin logins on the Xeon,
or one CPU can serve 25 WP admin logs on a cheaper setup. That seems like
significant enough to take into account, or at least do more investigation
into.
For example, we know that many web hosts disable loopback connections -
pointless, annoying, but they do it. If word gets round that you can spare
your CPUs + get more out of your servers by blocking heartbeat connections
("and all that happens is that WordPress users don't see login warnings,
or lose some advanced functionality"), that'll not be fun. I wonder if
something like login expiration warnings is worth taxing CPUs for every 15
seconds; or at least, the algorithm needs more attention. For example,
login-expiration time is known when the page loads. Wouldn't it make more
sense to just re-poll that once a minute before the known time rather than
ask the question every 15 seconds? Rather than having a heartbeat every 15
seconds regardless of demand, why not have a heartbeat only when demanded
by a consumer? (And for login expiration warnings, why not just use a one-
off JavaScript setTimeout rather than polling it anyway?).
--
Ticket URL: <http://core.trac.wordpress.org/ticket/23216#comment:61>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list