X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fobjectcache%2FMemcachedBagOStuff.php;h=813c2727c486c1196c198804755508769377a39a;hb=9846b1c1e9f473b79f581028dce06311530ef545;hp=131286623fd72a62e7033cc6807e4483ffc730ce;hpb=ebf2912801913acc724413a6e2967d78cae77223;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/objectcache/MemcachedBagOStuff.php b/includes/objectcache/MemcachedBagOStuff.php index 131286623f..813c2727c4 100644 --- a/includes/objectcache/MemcachedBagOStuff.php +++ b/includes/objectcache/MemcachedBagOStuff.php @@ -50,7 +50,7 @@ class MemcachedBagOStuff extends BagOStuff { $params['timeout'] = $GLOBALS['wgMemCachedTimeout']; } if ( !isset( $params['connect_timeout'] ) ) { - $params['connect_timeout'] = 0.1; + $params['connect_timeout'] = 0.5; } return $params; } @@ -86,6 +86,7 @@ class MemcachedBagOStuff extends BagOStuff { /** * @param $key string * @param $value int + * @param $exptime int (default 0) * @return Mixed */ public function add( $key, $value, $exptime = 0 ) { @@ -119,6 +120,7 @@ class MemcachedBagOStuff extends BagOStuff { * the other control characters for compatibility with libmemcached * verify_key. We leave other punctuation alone, to maximise backwards * compatibility. + * @param $key string * @return string */ public function encodeKey( $key ) { @@ -126,6 +128,10 @@ class MemcachedBagOStuff extends BagOStuff { array( $this, 'encodeKeyCallback' ), $key ); } + /** + * @param $m array + * @return string + */ protected function encodeKeyCallback( $m ) { return rawurlencode( $m[0] ); }