objectcache: Mention colons in BagOStuff key generation
authorAaron Schulz <aschulz@wikimedia.org>
Wed, 18 Oct 2017 21:25:23 +0000 (14:25 -0700)
committerKrinkle <krinklemail@gmail.com>
Fri, 20 Oct 2017 03:26:25 +0000 (03:26 +0000)
Change-Id: I76967245c32aac4eea8d6672e4fc1fac5e5f3d07

includes/libs/objectcache/BagOStuff.php
includes/libs/objectcache/WANObjectCache.php

index 8a23db5..d6cb340 100644 (file)
@@ -732,7 +732,7 @@ abstract class BagOStuff implements IExpiringStore, LoggerAwareInterface {
         * @since 1.27
         * @param string $keyspace
         * @param array $args
-        * @return string
+        * @return string Colon-delimited list of $keyspace followed by escaped components of $args
         */
        public function makeKeyInternal( $keyspace, $args ) {
                $key = $keyspace;
@@ -747,8 +747,8 @@ abstract class BagOStuff implements IExpiringStore, LoggerAwareInterface {
         * Make a global cache key.
         *
         * @since 1.27
-        * @param string $keys,... Key component
-        * @return string
+        * @param string $keys,... Key component (starting with a key collection name)
+        * @return string Colon-delimited list of $keyspace followed by escaped components of $args
         */
        public function makeGlobalKey() {
                return $this->makeKeyInternal( 'global', func_get_args() );
@@ -758,8 +758,8 @@ abstract class BagOStuff implements IExpiringStore, LoggerAwareInterface {
         * Make a cache key, scoped to this instance's keyspace.
         *
         * @since 1.27
-        * @param string $keys,... Key component
-        * @return string
+        * @param string $keys,... Key component (starting with a key collection name)
+        * @return string Colon-delimited list of $keyspace followed by escaped components of $args
         */
        public function makeKey() {
                return $this->makeKeyInternal( $this->keyspace, func_get_args() );
index cab5782..8ad2b93 100644 (file)
@@ -1315,8 +1315,8 @@ class WANObjectCache implements IExpiringStore, LoggerAwareInterface {
 
        /**
         * @see BagOStuff::makeKey()
-        * @param string $keys,... Key component
-        * @return string
+        * @param string $keys,... Key component (starting with a key collection name)
+        * @return string Colon-delimited list of $keyspace followed by escaped components of $args
         * @since 1.27
         */
        public function makeKey() {
@@ -1325,8 +1325,8 @@ class WANObjectCache implements IExpiringStore, LoggerAwareInterface {
 
        /**
         * @see BagOStuff::makeGlobalKey()
-        * @param string $keys,... Key component
-        * @return string
+        * @param string $keys,... Key component (starting with a key collection name)
+        * @return string Colon-delimited list of $keyspace followed by escaped components of $args
         * @since 1.27
         */
        public function makeGlobalKey() {