rdbms: better handle a non-existing "defaultGroup" in LoadBalancer
authorAaron Schulz <aschulz@wikimedia.org>
Mon, 15 Jul 2019 23:59:21 +0000 (16:59 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Tue, 16 Jul 2019 18:22:41 +0000 (18:22 +0000)
commit32df79f3d1966f41d6ddfb954a061361827499c2
tree9130c143f20aa0bf76fc1cfe67859c34a13feb06
parent1fc5525ebde9ef14a8c0edb49fd729ba27ca78e2
rdbms: better handle a non-existing  "defaultGroup" in LoadBalancer

If the specified default group does not have a corresponding server load map
defined, then ignore it and use GROUP_GENERIC.

Also, consolidate the group load and group reader index code for simplicity

Change-Id: Ic8bf9a3ebcbffb81fb14d7b1787a2adb97ac525d
includes/libs/rdbms/loadbalancer/ILoadBalancer.php
includes/libs/rdbms/loadbalancer/LoadBalancer.php
tests/phpunit/includes/db/LoadBalancerTest.php