r99107 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r99106‎ | r99107 | r99108 >
Date:14:09, 6 October 2011
Author:catrope
Status:ok
Tags:
Comment:
1.18wmf1: MFT r99106`
Modified paths:
  • /branches/wmf/1.18wmf1/includes/objectcache/MemcachedClient.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/includes/objectcache/MemcachedClient.php
@@ -959,9 +959,12 @@
960960 $this->stats[$cmd] = 1;
961961 }
962962
963 - // Memcached doesn't seem to handle very high TTL values very well,
964 - // so clamp them at 30 days
965 - if ( $exp > 2592000 ) {
 963+ // TTLs higher than 30 days will be detected as absolute TTLs
 964+ // (UNIX timestamps), and will result in the cache entry being
 965+ // discarded immediately because the expiry is in the past.
 966+ // Clamp expiries >30d at 30d, unless they're >=1e9 in which
 967+ // case they are likely to really be absolute (1e9 = 2011-09-09)
 968+ if ( $exp > 2592000 && $exp < 1000000000 ) {
966969 $exp = 2592000;
967970 }
968971

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r99106Per Domas, reinstate <1e9 check that was dropped in r94199. Also document wha...catrope14:07, 6 October 2011

Status & tagging log