summaryrefslogtreecommitdiffstats
path: root/nova/api
diff options
context:
space:
mode:
authorMichael J Fork <mjfork@us.ibm.com>2013-01-15 12:44:41 +0000
committerMichael J Fork <mjfork@us.ibm.com>2013-01-15 12:44:41 +0000
commitfc42f76b24df376c89f94a177f2476dacbc87073 (patch)
tree16db67227f5333b5de421697177f2bff0b70123e /nova/api
parent8fddd6ad445586dc2c59ace0b292ff9da7048561 (diff)
Populate service list with availability zone and correct unit test
Availability zone was removed from the service object and is now added via a separate call to availabilty_zones.set_availability_zones. Fix the fake_services_list structure in test_services to reflect that availability zone is no longer returned but added separately based on the topic. NOTE: original fix was reverted, combining unit test fix and original change here. bug 1099399 Change-Id: Ic9675a88c2c229d6feb20f5b934458e10c17684f
Diffstat (limited to 'nova/api')
-rw-r--r--nova/api/openstack/compute/contrib/services.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/nova/api/openstack/compute/contrib/services.py b/nova/api/openstack/compute/contrib/services.py
index c792c72da..2786ad814 100644
--- a/nova/api/openstack/compute/contrib/services.py
+++ b/nova/api/openstack/compute/contrib/services.py
@@ -21,6 +21,7 @@ import webob.exc
from nova.api.openstack import extensions
from nova.api.openstack import wsgi
from nova.api.openstack import xmlutil
+from nova import availability_zones
from nova import db
from nova import exception
from nova.openstack.common import cfg
@@ -69,6 +70,7 @@ class ServiceController(object):
authorize(context)
now = timeutils.utcnow()
services = db.service_get_all(context)
+ services = availability_zones.set_availability_zones(context, services)
host = ''
if 'host' in req.GET: