summaryrefslogtreecommitdiff
path: root/nova/scheduler
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2019-10-09 22:49:12 +0000
committerGerrit Code Review <review@openstack.org>2019-10-09 22:49:12 +0000
commit5345f9acb7cf3614c92ab3bac9ef66e5041d6617 (patch)
tree05a7b01b423beb39c6a00d3839628d52b6207268 /nova/scheduler
parentde5f7a69a27f68f312fc3ec48f272ab0ea23b282 (diff)
parent9981d06b4cd0e7af9cc819e0556b507ea34171c3 (diff)
downloadnova-5345f9acb7cf3614c92ab3bac9ef66e5041d6617.tar.gz
Merge "Remove @safe_connect from _delete_provider"
Diffstat (limited to 'nova/scheduler')
-rw-r--r--nova/scheduler/client/report.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/nova/scheduler/client/report.py b/nova/scheduler/client/report.py
index f9660da565..49a03c8166 100644
--- a/nova/scheduler/client/report.py
+++ b/nova/scheduler/client/report.py
@@ -389,7 +389,7 @@ class SchedulerReportClient(object):
:return: The name of the RP
:raise: ResourceProviderRetrievalFailed if the RP is not in the cache
and the communication with the placement is failed.
- :raise: ResourceProviderNotFound if the RP does not exists.
+ :raise: ResourceProviderNotFound if the RP does not exist.
"""
try:
@@ -667,7 +667,6 @@ class SchedulerReportClient(object):
return uuid
- @safe_connect
def _delete_provider(self, rp_uuid, global_request_id=None):
resp = self.delete('/resource_providers/%s' % rp_uuid,
global_request_id=global_request_id)
@@ -1293,6 +1292,8 @@ class SchedulerReportClient(object):
reshape (see below).
:raises: ReshapeFailed if a reshape was signaled (allocations not None)
and it fails for any reason.
+ :raises: keystoneauth1.exceptions.base.ClientException on failure to
+ communicate with the placement API
"""
# NOTE(efried): We currently do not handle the "rename" case. This is
# where new_tree contains a provider named Y whose UUID already exists
@@ -2000,7 +2001,7 @@ class SchedulerReportClient(object):
if allocations['allocations'] == {}:
# the consumer did not exist in the first place
LOG.debug('Cannot delete allocation for %s consumer in placement '
- 'as consumer does not exists', uuid)
+ 'as consumer does not exist', uuid)
return False
# removing all resources from the allocation will auto delete the
@@ -2131,8 +2132,9 @@ class SchedulerReportClient(object):
:param compute_node: The nova.objects.ComputeNode object that is the
resource provider being deleted.
:param cascade: Boolean value that, when True, will first delete any
- associated Allocation and Inventory records for the
- compute node
+ associated Allocation records for the compute node
+ :raises: keystoneauth1.exceptions.base.ClientException on failure to
+ communicate with the placement API
"""
nodename = compute_node.hypervisor_hostname
host = compute_node.host