state: Use StatePool instead of ForModel in AllModelWatcher #7512

Merged
merged 3 commits into from Jun 19, 2017

Conversation

Projects
None yet
3 participants
Contributor

mjs commented Jun 19, 2017

Description of change

ForModel is inefficient. Starting a AllModelWatcher on a controller with many models would have had a significant resource impact.

Also a drive-by fix for an incorrect call in state/logdb.

QA steps

Bootstrapped a new controller and then connected using this client: https://gist.github.com/mjs/d9d016433e4348b4aa990a8f81d65d03

Deployed software in multiple models and ensured that all expected changes were observed.

Documentation changes

N.A.

Bug reference

https://bugs.launchpad.net/juju/+bug/1698701

mjs added some commits Jun 19, 2017

state: Use StatePool instead of ForModel in AllModelWatcher
ForModel is inefficient. Starting a AllModelWatcher on a controller
with many models would have had a significant resource impact.
apiserver/controller: Add StatePool to test facade
This is required now that the allModelWatcher uses a StatePool when
initialising.
Contributor

mjs commented Jun 19, 2017

$$merge$$

Contributor

jujubot commented Jun 19, 2017

Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju

@jujubot jujubot merged commit 725099c into juju:2.2 Jun 19, 2017

1 check passed

github-check-merge-juju Ran tests against PR. Use !!.*!! to request another build. IE, !!build!!, !!retry!!
Details

@mjs mjs deleted the mjs:1698701-AllModelWatcher-ForModel-2.2 branch Jun 19, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment