summaryrefslogtreecommitdiff
path: root/includes/db/LBFactory.php
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2015-12-17 09:15:42 +0100
committerPierre Schmitz <pierre@archlinux.de>2015-12-17 09:44:51 +0100
commita1789ddde42033f1b05cc4929491214ee6e79383 (patch)
tree63615735c4ddffaaabf2428946bb26f90899f7bf /includes/db/LBFactory.php
parent9e06a62f265e3a2aaabecc598d4bc617e06fa32d (diff)
Update to MediaWiki 1.26.0
Diffstat (limited to 'includes/db/LBFactory.php')
-rw-r--r--includes/db/LBFactory.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/includes/db/LBFactory.php b/includes/db/LBFactory.php
index 4551e2d7..cf522b20 100644
--- a/includes/db/LBFactory.php
+++ b/includes/db/LBFactory.php
@@ -178,6 +178,15 @@ abstract class LBFactory {
}
/**
+ * Commit on all connections. Done for two reasons:
+ * 1. To commit changes to the masters.
+ * 2. To release the snapshot on all connections, master and slave.
+ */
+ public function commitAll() {
+ $this->forEachLBCallMethod( 'commitAll' );
+ }
+
+ /**
* Commit changes on all master connections
*/
public function commitMasterChanges() {
@@ -199,7 +208,7 @@ abstract class LBFactory {
*/
public function hasMasterChanges() {
$ret = false;
- $this->forEachLB( function ( $lb ) use ( &$ret ) {
+ $this->forEachLB( function ( LoadBalancer $lb ) use ( &$ret ) {
$ret = $ret || $lb->hasMasterChanges();
} );
return $ret;