| @@ 416-420 (lines=5) @@ | ||
| 413 | $i = ArrayUtils::pickRandom( $readLoads ); |
|
| 414 | } |
|
| 415 | ||
| 416 | if ( $i > 0 ) { |
|
| 417 | $ok = $this->doWait( $i, true, $timeout ); |
|
| 418 | } else { |
|
| 419 | $ok = true; // no applicable loads |
|
| 420 | } |
|
| 421 | ||
| 422 | return $ok; |
|
| 423 | } |
|
| @@ 437-439 (lines=3) @@ | ||
| 434 | ||
| 435 | $ok = true; |
|
| 436 | for ( $i = 1; $i < $serverCount; $i++ ) { |
|
| 437 | if ( $this->mLoads[$i] > 0 ) { |
|
| 438 | $ok = $this->doWait( $i, true, $timeout ) && $ok; |
|
| 439 | } |
|
| 440 | } |
|
| 441 | ||
| 442 | return $ok; |
|