[wp-trac] [WordPress Trac] #22661: Allow object caches to degrade gracefully

WordPress Trac noreply at wordpress.org
Fri Jan 23 16:01:54 UTC 2015


#22661: Allow object caches to degrade gracefully
--------------------------+-----------------------------
 Reporter:  markjaquith   |       Owner:
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:  Future Release
Component:  Cache API     |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  2nd-opinion   |     Focuses:
--------------------------+-----------------------------
Changes (by jipmoors):

 * keywords:  has-patch 2nd-opinion => 2nd-opinion


Comment:

 Another idea is to always include the cache.php from core and add filters
 to the public functions.
 This way the functions act as a permanent gateway into the custom cache
 implementations, which would give us more security and testing abilities.

 Also this solution would supply a clean way for the cache to have one or
 more fallbacks, which should give cache plugin creators more freedom and
 cleaner code.

 So far the only problem with this approach is that wp_cache_get has the
 4th parameter &$found, which a null check would provide for a correct
 response.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/22661#comment:12>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list