Remove instance action logging mechanism

* Remove InstanceActions db model
* Remove relevant db api functions
* Add migration 93 which drops the instance_actions
* Remove server_action_list API extension
* Fixes bug 994846

Change-Id: Ibbd787183034314460f41c84b9ad152655739209
This commit is contained in:
Brian Waldon
2012-05-04 14:36:52 -07:00
parent acaf5c7494
commit df8f599628
3 changed files with 0 additions and 28 deletions

View File

@@ -13,7 +13,6 @@
"compute:delete_instance_metadata": [],
"compute:get_instance_faults": [],
"compute:get_actions": [],
"compute:get_diagnostics": [],
"compute:get_lock": [],
@@ -104,7 +103,6 @@
"compute_extension:quota_classes": [],
"compute_extension:rescue": [],
"compute_extension:security_groups": [],
"compute_extension:server_action_list": [],
"compute_extension:server_diagnostics": [],
"compute_extension:simple_tenant_usage:show": [],
"compute_extension:simple_tenant_usage:list": [],

View File

@@ -3362,27 +3362,6 @@ class ComputeAPITestCase(BaseTestCase):
self.compute_api.get_diagnostics(self.context, instance)
self.compute_api.delete(self.context, instance)
def test_get_actions(self):
expected = [{'id': 1,
'instance_id': 5,
'action': 'rebuild',
'error': '',
}]
def fake_get_actions(context, instance):
return expected
self.stubs.Set(nova.db, 'instance_get_actions',
fake_get_actions)
instance = self._create_fake_instance()
context = self.context.elevated()
actual = self.compute_api.get_actions(context, instance)
self.assertEqual(expected, actual)
self.compute_api.delete(self.context, instance)
def test_inject_file(self):
"""Ensure we can write a file to an instance"""
instance = self._create_fake_instance()

View File

@@ -92,10 +92,6 @@ def stub_out_db_instance_api(stubs):
'vlan': 100}
return FakeModel(fields)
def fake_instance_action_create(context, action):
"""Stubs out the db.instance_action_create method."""
pass
def fake_instance_type_get_all(context, inactive=0, filters=None):
return INSTANCE_TYPES.values()
@@ -104,6 +100,5 @@ def stub_out_db_instance_api(stubs):
stubs.Set(db, 'instance_create', fake_instance_create)
stubs.Set(db, 'network_get_by_instance', fake_network_get_by_instance)
stubs.Set(db, 'instance_action_create', fake_instance_action_create)
stubs.Set(db, 'instance_type_get_all', fake_instance_type_get_all)
stubs.Set(db, 'instance_type_get_by_name', fake_instance_type_get_by_name)