Opened 14 years ago
Closed 14 years ago
#22190 closed defect (bug) (fixed)
Delete oEmbed caches on pre_post_update so cached meta is used
| Reported by: | nacin | Owned by: | nacin |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.5 |
| Component: | Performance | Version: | |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: |
Description
WP_Embed::delete_oembed_caches() is hooked into 'save_post', after which it calls get_post_meta() in a roundabout way. This results in an automatic update_meta_cache() call for a saved post, when it may not be otherwise needed for the rest of that pageload.
By moving oEmbed deletion to pre_post_update, we're able to use metadata that is more likely to already be in cache. If it is not already in cache but we do need metadata after, this could potentially add a query. But, I think the tradeoff is worth it.
Parent ticket: #22189. Saving navigation menus are slow.
Attachments (1)
Change History (2)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
In 22369: