Aaron Schulz has submitted this change and it was merged.
Change subject: Add LBFactory::closeAll() method
......................................................................
Add LBFactory::closeAll() method
Needed to allow long-running background tasks to close out database
connections in a way that allows them to reopen later when needed
again.
Bug: T97641
Change-Id: I4974b691392d4225b15e7b771a28a2cefeb9d8e4
---
M includes/db/loadbalancer/LBFactory.php
1 file changed, 9 insertions(+), 0 deletions(-)
Approvals:
Aaron Schulz: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/db/loadbalancer/LBFactory.php
b/includes/db/loadbalancer/LBFactory.php
index b78793f..5b048b5 100644
--- a/includes/db/loadbalancer/LBFactory.php
+++ b/includes/db/loadbalancer/LBFactory.php
@@ -452,6 +452,15 @@
}
} );
}
+
+ /**
+ * Close all open database connections on all open load balancers.
+ * @since 1.28
+ */
+ public function closeAll() {
+ $this->forEachLBCallMethod( 'closeAll', [] );
+ }
+
}
/**
--
To view, visit https://gerrit.wikimedia.org/r/290478
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I4974b691392d4225b15e7b771a28a2cefeb9d8e4
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Brion VIBBER <[email protected]>
Gerrit-Reviewer: Aaron Schulz <[email protected]>
Gerrit-Reviewer: Brion VIBBER <[email protected]>
Gerrit-Reviewer: Parent5446 <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits