Merge "Cache lb_plugin in the loadbalancer driver"
This commit is contained in:
commit
c84105ef24
@ -256,11 +256,14 @@ class EdgeLbDriver(object):
|
|||||||
# self.vcns is initialized by subclass
|
# self.vcns is initialized by subclass
|
||||||
self.vcns = None
|
self.vcns = None
|
||||||
self._fw_section_id = None
|
self._fw_section_id = None
|
||||||
|
self._lb_plugin = None
|
||||||
self._lb_driver_prop = None
|
self._lb_driver_prop = None
|
||||||
|
|
||||||
def _get_lb_plugin(self):
|
def _get_lb_plugin(self):
|
||||||
|
if not self._lb_plugin:
|
||||||
loaded_plugins = manager.NeutronManager().get_service_plugins()
|
loaded_plugins = manager.NeutronManager().get_service_plugins()
|
||||||
return loaded_plugins[constants.LOADBALANCER]
|
self._lb_plugin = loaded_plugins[constants.LOADBALANCER]
|
||||||
|
return self._lb_plugin
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def _lb_driver(self):
|
def _lb_driver(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user