Make WordPress Core

Opened 12 years ago

Last modified 2 years ago

#27776 assigned defect (bug)

WordPress API timeouts should be cached to avoid slowing down the admin

Reported by: anonymized_6656123 Owned by: pbearne
Priority: normal Milestone:
Component: Administration Version: 3.3
Severity: normal Keywords:
Cc: Focuses: performance

Description

The admin does several calls to the WordPress API, such as from the wp_check_browser_version function. These calls don't cache timeouts, which means if the API is consistently timing out the admin is slow on every load as all of these calls must timeout before the page can load.

I propose we cache timeouts using transients, for a day.

This behavior has been present since at least 3.3 and is still the behavior on trunk.

Change History (7)

#2 @MikeHansenMe
12 years ago

I too have run into this problem.

#3 @DrewAPicture
12 years ago

  • Component GeneralAdministration
  • Focuses administration removed

#4 @DrewAPicture
12 years ago

  • Focuses performance added

#5 @valendesigns
12 years ago

I think caching for an entire day could be overkill, since the problem could be intermittent and not last 24 hours. Something along the lines of 30 minutes seems reasonable enough to free up resources and still be actively looking for an API connection.

#6 @pbearne
2 years ago

  • Owner set to pbearne
  • Status newassigned

The question that I have is whether it should be in the wp_remote calls rather than in the consuming call

Will this still be needed for the new admin?

Happy to add the code if still needed

#7 @pbearne
2 years ago

added some tests for wp_check_browser_version in https://core.trac.wordpress.org/ticket/60828

But could get the call to time out so I wonder if we need to do this

Note: See TracTickets for help on using tickets.