dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e47f857
)
Do not count 0-load servers in getMaxLag()
author
Aaron Schulz
<aschulz@wikimedia.org>
Sat, 21 May 2016 10:40:03 +0000
(
03:40
-0700)
committer
Ori.livneh
<ori@wikimedia.org>
Mon, 23 May 2016 18:42:56 +0000
(18:42 +0000)
JobRunner::run() and API endpoints use this to bail out if
lag is too high. A dedicated "vslow" host with no normal
load should not trigger this logic, for example.
Bug: T135809
Change-Id: If6879aa1a4379857779a4eacf2a8b7400c0b434f
includes/db/loadbalancer/LoadBalancer.php
patch
|
blob
|
history
diff --git
a/includes/db/loadbalancer/LoadBalancer.php
b/includes/db/loadbalancer/LoadBalancer.php
index
5578099
..
1f2f494
100644
(file)
--- a/
includes/db/loadbalancer/LoadBalancer.php
+++ b/
includes/db/loadbalancer/LoadBalancer.php
@@
-1334,7
+1334,7
@@
class LoadBalancer {
$lagTimes = $this->getLagTimes( $wiki );
foreach ( $lagTimes as $i => $lag ) {
- if ( $lag > $maxLag ) {
+ if ( $
this->mLoads[$i] > 0 && $
lag > $maxLag ) {
$maxLag = $lag;
$host = $this->mServers[$i]['host'];
$maxIndex = $i;