[wp-trac] [WordPress Trac] #23167: Cache incrementors for get_pages

WordPress Trac noreply at wordpress.org
Wed Jan 30 19:41:18 UTC 2013


#23167: Cache incrementors for get_pages
----------------------------------------+------------------------
 Reporter:  nprasath002                 |       Owner:  westi
     Type:  task (blessed)              |      Status:  reviewing
 Priority:  normal                      |   Milestone:  3.6
Component:  Cache                       |     Version:  3.5
 Severity:  normal                      |  Resolution:
 Keywords:  has-patch needs-unit-tests  |
----------------------------------------+------------------------

Comment (by mark-k):

 Resetting $last_changed to 1 is wrong. It is very unlikely but if
 $last_changed got purged from cache while the content of the buckets
 remained (it was on different memcache server which failed) you might get
 a key which points to old data which might still be in the cache.
 In other words this way you increase the possibility of key collision.

 IMO it is better to use a random initial seed every time it needs to be
 calculated.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/23167#comment:16>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list