ensure syncs trickle down
Signed-off-by: Travis Glenn Hansen <travisghansen@yahoo.com>
This commit is contained in:
parent
7137389b6c
commit
6e6d331bd9
1 changed files with 10 additions and 0 deletions
|
@ -57,7 +57,17 @@ function _M.pick_new_upstream(self, failed_upstreams)
|
||||||
end
|
end
|
||||||
|
|
||||||
function _M.sync(self, backend)
|
function _M.sync(self, backend)
|
||||||
|
-- sync inherited balancer
|
||||||
|
balancer_sticky.sync(self, backend)
|
||||||
|
|
||||||
|
-- note this may be inefficient
|
||||||
|
-- perhaps better to only update if name changes?
|
||||||
self.secondary_balancer = get_secondary_balancer(backend)
|
self.secondary_balancer = get_secondary_balancer(backend)
|
||||||
|
|
||||||
|
-- sync secondary_balancer as well
|
||||||
|
if self.secondary_balancer then
|
||||||
|
self.secondary_balancer:sync(backend)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
return _M
|
return _M
|
||||||
|
|
Loading…
Reference in a new issue