Page MenuHomeIn-Portal Phabricator

D365.diff
No OneTemporary

File Metadata

Created
Fri, Jul 18, 10:27 PM

D365.diff

Index: branches/5.2.x/core/kernel/db/db_load_balancer.php
===================================================================
--- branches/5.2.x/core/kernel/db/db_load_balancer.php
+++ branches/5.2.x/core/kernel/db/db_load_balancer.php
@@ -176,8 +176,8 @@
*/
protected function getSlaveIndex()
{
- if ( count($this->servers) == 1 || $this->Application->isAdmin ) {
- // skip the load balancing if there's only one server OR in admin console
+ if ( count($this->servers) == 1 || $this->Application->isAdmin || defined('CRON') ) {
+ // Skip the load balancing if there's only one server OR in admin console OR in CRON.
return 0;
}
elseif ( $this->slaveIndex !== false ) {

Event Timeline