#35323 closed defect (bug) (fixed)
Reschedule the Background Update cron for improved performance.
Reported by: | dd32 | Owned by: | dd32 |
---|---|---|---|
Milestone: | 4.4.1 | Priority: | normal |
Severity: | normal | Version: | 3.7 |
Component: | Upgrade/Install | Keywords: | |
Focuses: | Cc: |
Description
When we first added Background Updates to WordPress in 3.7, we added a twice daily update check at approximately 7am "local time" (according to the blogs settings).
What we didn't realise at the time, was that many sites have their timezone settings set to UTC
even though the site isn't "based" in the UTC timezone (See #28988).
What this has effectively caused is that WordPress.org gets a large surge of API requests around 7am and 7pm UTC daily which lasts approximately 2 hours, during which the API requests are over twice the rate outside of that time.
The 7am/7pm time slot is really not anything special anymore, the vast majority of WordPress background updates now happen within an hour of our release time through good planning.
We should attempt to reduce the sudden surge of API requests to WordPress.org by re-scheduling the 7am/7pm daily job to a random minute during the day instead, it'll help with future WordPress.org API growth and ensure that a more consistent API response time is provided.
We could either only re-schedule it if it falls within that time slot, or as it's not guaranteed to run at that time anyway, reset every schedule to a random minute instead.
This needs a patch, but I'd suggest it be backported all the way down to 3.7 and implemented as a once-off upgrade routine.
FYI @nacin
Attachments (1)
Change History (6)
#2
@
9 years ago
After looking closer, it was realised that we no longer need this extra schedule.
It's only purpose in life was to run the 7am/7pm background updates, and those are now kicked off by the core version check in WordPress 3.9+, that schedule was already at a random second of the day.
#3
@
9 years ago
- Owner set to dd32
- Resolution set to fixed
- Status changed from new to closed
In 36184:
#4
@
9 years ago
- Keywords needs-patch removed
- Milestone changed from 4.5 to 4.4.1
I apologise for the late 4.4.1 commit, the performance aspects make it worthwhile though.
I've tested the minimal patch on all versions, with the 3.7/3.8 changes getting extra attention.
In 36180: