Use the util.import_object to import a module.
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
# under the License.
|
||||
|
||||
|
||||
from nova.utils import load_module
|
||||
from nova.utils import import_object
|
||||
from nova.rpc_backends.common import RemoteError, LOG
|
||||
from nova import flags
|
||||
|
||||
@@ -26,7 +26,7 @@ flags.DEFINE_string('rpc_backend',
|
||||
'nova.rpc_backends.amqp',
|
||||
"The messaging module to use, defaults to AMQP.")
|
||||
|
||||
RPCIMPL = load_module(FLAGS.rpc_backend)
|
||||
RPCIMPL = import_object(FLAGS.rpc_backend)
|
||||
|
||||
|
||||
def create_connection(new=True):
|
||||
|
||||
Reference in New Issue
Block a user