Merge "Fix issues with check_instance_shared_storage."
This commit is contained in:
commit
6b2af9c084
@ -3073,7 +3073,7 @@ class ComputeManager(manager.SchedulerDependentManager):
|
||||
raise exception.NotFound(_("Host %(host)s not found") % locals())
|
||||
|
||||
@exception.wrap_exception(notifier=notifier, publisher_id=publisher_id())
|
||||
def check_instance_shared_storage(self, ctxt, data):
|
||||
def check_instance_shared_storage(self, ctxt, instance, data):
|
||||
"""Check if the instance files are shared
|
||||
|
||||
:param context: security context
|
||||
|
@ -251,9 +251,11 @@ class ComputeAPI(nova.openstack.common.rpc.proxy.RpcProxy):
|
||||
def check_instance_shared_storage(self, ctxt, instance, data):
|
||||
instance_p = jsonutils.to_primitive(instance)
|
||||
return self.call(ctxt, self.make_msg('check_instance_shared_storage',
|
||||
instance=instance_p,
|
||||
data=data),
|
||||
topic=_compute_topic(self.topic, ctxt, None,
|
||||
instance))
|
||||
instance),
|
||||
version='2.28')
|
||||
|
||||
def confirm_resize(self, ctxt, instance, migration, host,
|
||||
reservations=None, cast=True):
|
||||
|
@ -122,6 +122,10 @@ class ComputeRpcAPITestCase(test.TestCase):
|
||||
instance=self.fake_instance,
|
||||
dest_check_data={"test": "data"})
|
||||
|
||||
def test_check_instance_shared_storage(self):
|
||||
self._test_compute_api('check_instance_shared_storage', 'call',
|
||||
instance=self.fake_instance, data='foo', version='2.28')
|
||||
|
||||
def test_confirm_resize_cast(self):
|
||||
self._test_compute_api('confirm_resize', 'cast',
|
||||
instance=self.fake_instance, migration={'id': 'foo'},
|
||||
|
Loading…
x
Reference in New Issue
Block a user