Browse Source

Fix HTTP 400 error

This is kind of a race condition issue, Tempest is doing a wait and check
when it is trying to delete a cluster. However, at the very end of the cluster
deletion process, a cluster GET request may get a HTTP 400 error which
will cause the Tempest case failed. This HTTP 400 exception reported
by a cluster GET request should be caught and take cluster as still existing.

Task: 40120
Story: 2007833

Change-Id: Ic97abf8d4d584f35b18bff9eab5d3e5ac80c0f02
changes/36/736936/3
Feilong Wang 2 weeks ago
parent
commit
abe58fe334
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      magnum_tempest_plugin/tests/api/v1/clients/cluster_client.py

+ 5
- 0
magnum_tempest_plugin/tests/api/v1/clients/cluster_client.py View File

@@ -171,4 +171,9 @@ class ClusterClient(client.MagnumClient):
except exceptions.NotFound:
self.LOG.warning('Cluster %s is not found.', cluster_id)
return True
except exceptions.BadRequest:
self.LOG.warning('Cluster %s returned a bad state. Assuming '
'temporary failure and the cluster still exists.',
cluster_id)
return False
return False

Loading…
Cancel
Save