From 5157401f20158b2b99d01796f73a8ba5368c80a2 Mon Sep 17 00:00:00 2001 From: Brian Lamar Date: Fri, 8 Jun 2012 15:18:13 -0400 Subject: Do not always query deleted instance_types. When converting from flavorid to instance_type_id in the OSAPI, it isn't always desired to return deleted instance_types. In the case of OSAPI create(), we explicitly do not want to query deleted flavors. Fixes bug 1010638 Change-Id: I9c26c7130f8c3d6680143e36b4aaa1f662c682a7 --- nova/api/openstack/compute/servers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nova/api') diff --git a/nova/api/openstack/compute/servers.py b/nova/api/openstack/compute/servers.py index 64af7222f..a92d9b6bb 100644 --- a/nova/api/openstack/compute/servers.py +++ b/nova/api/openstack/compute/servers.py @@ -676,7 +676,7 @@ class Controller(wsgi.Controller): try: _get_inst_type = instance_types.get_instance_type_by_flavor_id - inst_type = _get_inst_type(flavor_id) + inst_type = _get_inst_type(flavor_id, read_deleted="no") (instances, resv_id) = self.compute_api.create(context, inst_type, -- cgit