Merge "Properly mark UserGetImplicitGroups hook as deprecated"
[lhc/web/wiklou.git] / includes / filebackend / SwiftFileBackend.php
index e9c8883..7234474 100644 (file)
@@ -112,7 +112,7 @@ class SwiftFileBackend extends FileBackendStore {
                // Optional settings
                $this->authTTL = isset( $config['swiftAuthTTL'] )
                        ? $config['swiftAuthTTL']
-                       : 5 * 60; // some sane number
+                       : 15 * 60; // some sane number
                $this->swiftTempUrlKey = isset( $config['swiftTempUrlKey'] )
                        ? $config['swiftTempUrlKey']
                        : '';
@@ -173,7 +173,7 @@ class SwiftFileBackend extends FileBackendStore {
         * Sanitize and filter the custom headers from a $params array.
         * We only allow certain Content- and X-Content- headers.
         *
-        * @param array $headers
+        * @param array $params
         * @return array Sanitized value of 'headers' field in $params
         */
        protected function sanitizeHdrs( array $params ) {
@@ -537,6 +537,7 @@ class SwiftFileBackend extends FileBackendStore {
                        return $status; // already there
                } elseif ( $stat === null ) {
                        $status->fatal( 'backend-fail-internal', $this->name );
+                       wfDebugLog( 'SwiftBackend', __METHOD__ . ': cannot get container stat' );
 
                        return $status;
                }
@@ -568,6 +569,7 @@ class SwiftFileBackend extends FileBackendStore {
                        $status->fatal( 'backend-fail-usable', $params['dir'] );
                } else {
                        $status->fatal( 'backend-fail-internal', $this->name );
+                       wfDebugLog( 'SwiftBackend', __METHOD__ . ': cannot get container stat' );
                }
 
                return $status;
@@ -588,6 +590,7 @@ class SwiftFileBackend extends FileBackendStore {
                        $status->fatal( 'backend-fail-usable', $params['dir'] );
                } else {
                        $status->fatal( 'backend-fail-internal', $this->name );
+                       wfDebugLog( 'SwiftBackend', __METHOD__ . ': cannot get container stat' );
                }
 
                return $status;
@@ -607,6 +610,7 @@ class SwiftFileBackend extends FileBackendStore {
                        return $status; // ok, nothing to do
                } elseif ( !is_array( $stat ) ) {
                        $status->fatal( 'backend-fail-internal', $this->name );
+                       wfDebugLog( 'SwiftBackend', __METHOD__ . ': cannot get container stat' );
 
                        return $status;
                }
@@ -1253,6 +1257,7 @@ class SwiftFileBackend extends FileBackendStore {
 
                if ( $rcode != 204 && $rcode !== 202 ) {
                        $status->fatal( 'backend-fail-internal', $this->name );
+                       wfDebugLog( 'SwiftBackend', __METHOD__ . ': unexpected rcode value (' . $rcode . ')' );
                }
 
                return $status;