Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F804057
D365.id966.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Wed, Feb 26, 9:05 AM
Size
693 B
Mime Type
text/x-diff
Expires
Thu, Feb 27, 9:05 AM (1 h, 21 m)
Engine
blob
Format
Raw Data
Handle
576771
Attached To
D365: INP-1768 - Disable Load Balancing from CRON
D365.id966.diff
View Options
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
Log In to Comment