Make compute_api confirm/revert resize use objects

This makes the compute_api confirm and revert_resize calls use
and return Migration objects for its work.  This also adds the
cells RPC methods needed to support child cells re-calling the
compute API with objects.

Related to blueprint compute-api-objects

Change-Id: I26adc8d2fadc4a31cd0de94887e163040691ede1
This commit is contained in:
Dan Smith
2013-08-13 11:54:47 -07:00
committed by Chris Behrens
parent a2ba455e2d
commit 5d0ccceb20
14 changed files with 218 additions and 119 deletions

View File

@@ -752,3 +752,15 @@ class CellsManagerClassTestCase(test.TestCase):
self.ctxt, instance='fake-instance',
block_migration='fake-block', disk_over_commit='fake-commit',
host_name='fake-host')
def test_revert_resize(self):
self.mox.StubOutWithMock(self.msg_runner, 'revert_resize')
self.msg_runner.revert_resize(self.ctxt, 'fake-instance')
self.mox.ReplayAll()
self.cells_manager.revert_resize(self.ctxt, instance='fake-instance')
def test_confirm_resize(self):
self.mox.StubOutWithMock(self.msg_runner, 'confirm_resize')
self.msg_runner.confirm_resize(self.ctxt, 'fake-instance')
self.mox.ReplayAll()
self.cells_manager.confirm_resize(self.ctxt, instance='fake-instance')