Skip to:
Content

bbPress.org


Ignore:
Timestamp:
06/19/2017 05:05:18 AM (9 years ago)
Author:
johnjamesjacoby
Message:

Cache: make bbp_clean_post_cache() an action-only function.

Instead of calling bbp_clean_post_cache() directly, we'll call clean_post_cache() as per normal and hook bbp_clean_post_cache() to the end of it. This reduces a bunch of superfluous cache invalidation from occurring back-to-back.

We'll also only ever update the last_changed cache key when we've reached the forum-root. This makes sure that subsequent recursive calls up the post_parent tree are dealing with the same last_changed value until the end.

This change will reduce the number of cache invalidation calls by a large amount, improving functional performance for database writes to the post & postmeta tables.

File:
1 edited

Legend:

Unmodified
Added
Removed
Note: See TracChangeset for help on using the changeset viewer.