[wp-trac] [WordPress Trac] #35381: Introduce `WP_Term_Query`
WordPress Trac
noreply at wordpress.org
Thu May 26 00:02:07 UTC 2016
#35381: Introduce `WP_Term_Query`
--------------------------------------------------+------------------
Reporter: boonebgorges | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.6
Component: Taxonomy | Version:
Severity: normal | Resolution:
Keywords: has-patch needs-testing dev-feedback | Focuses:
--------------------------------------------------+------------------
Comment (by spacedmonkey):
Is there a good reason why the results are only cached for a day? See the
following line
{{{#!php
wp_cache_add( $cache_key, $terms, 'terms', DAY_IN_SECONDS )
}}}
If is confusing, a day seems like a random amount of time. The cache key
changes on term cache clean anyway, so it should stay in cache forever
right?
I also think that the value stored in cache should be just an array of
ids. I don't think we should be storing the whole object in there, as it
not required and will just use up memory.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/35381#comment:12>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list