Merge "Convert WatchedItemQueryService to using getConnectionRef()"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Sat, 8 Oct 2016 16:32:45 +0000 (16:32 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Sat, 8 Oct 2016 16:32:45 +0000 (16:32 +0000)
docs/hooks.txt
includes/libs/rdbms/loadmonitor/LoadMonitor.php
includes/page/WikiPage.php

index cccd13d..3b3741a 100644 (file)
@@ -1243,7 +1243,7 @@ $out: OutputPage object
 $parserOutput: ParserOutput object
 $wikiPage: WikiPage object
 
-DifferenceEngineRenderRevisionShowFinalPatrolLink': An extension can hook into this hook
+'DifferenceEngineRenderRevisionShowFinalPatrolLink': An extension can hook into this hook
 point and return false to not show the final "mark as patrolled" link on the bottom
 of a page.
 This hook has no arguments.
index 499542d..99c9126 100644 (file)
@@ -160,10 +160,14 @@ class LoadMonitor implements ILoadMonitor {
                                continue;
                        }
 
-                       $lagTimes[$i] = $conn->getLag();
-                       if ( $lagTimes[$i] === false ) {
-                               $host = $this->parent->getServerName( $i );
-                               $this->replLogger->error( __METHOD__ . ": host $host is not replicating?" );
+                       if ( $conn->getLBInfo( 'is static' ) ) {
+                               $lagTimes[$i] = 0;
+                       } else {
+                               $lagTimes[$i] = $conn->getLag();
+                               if ( $lagTimes[$i] === false ) {
+                                       $host = $this->parent->getServerName( $i );
+                                       $this->replLogger->error( __METHOD__ . ": host $host is not replicating?" );
+                               }
                        }
 
                        if ( $close ) {
index 2833965..c791587 100644 (file)
@@ -2075,7 +2075,7 @@ class WikiPage implements Page, IDBAccessObject {
         * @return object
         */
        public function prepareTextForEdit( $text, $revid = null, User $user = null ) {
-               ContentHandler::deprecated( __METHOD__, '1.21' );
+               wfDeprecated( __METHOD__, '1.21' );
                $content = ContentHandler::makeContent( $text, $this->getTitle() );
                return $this->prepareContentForEdit( $content, $revid, $user );
        }