[wp-trac] [WordPress Trac] #39242: Add caching to count_user_posts()
WordPress Trac
noreply at wordpress.org
Sun Mar 2 21:47:34 UTC 2025
#39242: Add caching to count_user_posts()
-------------------------------------------------+-------------------------
Reporter: johnjamesjacoby | Owner:
| spacedmonkey
Type: enhancement | Status: reopened
Priority: normal | Milestone: 6.8
Component: Users | Version: 3.0
Severity: normal | Resolution:
Keywords: has-patch needs-testing has-unit- | Focuses: rest-api,
tests commit | performance
-------------------------------------------------+-------------------------
Changes (by peterwilsoncc):
* status: closed => reopened
* resolution: fixed =>
Comment:
@spacedmonkey @johnjamesjacoby Reviewing #63004, I noticed that
`count_many_users_posts()` doesn't use the cache. That's probaly fine for
now it occurs to me that we might need to change the cache key to allow
for easier generation between the two functions if it's changed in the
future. (Checks notes, and yes I was encouraging the use of the query for
the cache key earlier :)
--
Ticket URL: <https://core.trac.wordpress.org/ticket/39242#comment:39>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list