summaryrefslogtreecommitdiffstats
path: root/nova/manager.py
diff options
context:
space:
mode:
Diffstat (limited to 'nova/manager.py')
-rw-r--r--nova/manager.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/nova/manager.py b/nova/manager.py
index a74caa8f6..c6711aadb 100644
--- a/nova/manager.py
+++ b/nova/manager.py
@@ -56,6 +56,7 @@ This module provides Manager, a base class for managers.
from nova.db import base
from nova import flags
from nova.openstack.common import log as logging
+from nova.openstack.common.plugin import pluginmanager
from nova.openstack.common.rpc import dispatcher as rpc_dispatcher
from nova.scheduler import rpcapi as scheduler_rpcapi
from nova import version
@@ -138,8 +139,13 @@ class Manager(base.Base):
if not host:
host = FLAGS.host
self.host = host
+ self.load_plugins()
super(Manager, self).__init__(db_driver)
+ def load_plugins(self):
+ pluginmgr = pluginmanager.PluginManager('nova', self.__class__)
+ pluginmgr.load_plugins()
+
def create_rpc_dispatcher(self):
'''Get the rpc dispatcher for this manager.
@@ -205,6 +211,10 @@ class SchedulerDependentManager(Manager):
self.scheduler_rpcapi = scheduler_rpcapi.SchedulerAPI()
super(SchedulerDependentManager, self).__init__(host, db_driver)
+ def load_plugins(self):
+ pluginmgr = pluginmanager.PluginManager('nova', self.service_name)
+ pluginmgr.load_plugins()
+
def update_service_capabilities(self, capabilities):
"""Remember these capabilities to send on next periodic update."""
self.last_capabilities = capabilities