Merge "Do not catch all exceptions when deleting a nsgroup" into stable/ussuri

This commit is contained in:
Zuul 2020-06-24 12:28:13 +00:00 committed by Gerrit Code Review
commit 01e9d55c24
1 changed files with 2 additions and 7 deletions

View File

@ -201,13 +201,8 @@ class NsxLibNsGroup(utils.NsxLibApiBase):
'%s?populate_references=true' % self.get_path(nsgroup_id)) '%s?populate_references=true' % self.get_path(nsgroup_id))
def delete(self, nsgroup_id): def delete(self, nsgroup_id):
try: resource = '%s?force=true' % nsgroup_id
return self._delete_by_path_with_retry( return self._delete_with_retry(resource)
'%s?force=true' % self.get_path(nsgroup_id))
# FIXME(roeyc): Should only except NotFound error.
except Exception:
LOG.debug("NSGroup %s does not exists for delete request.",
nsgroup_id)
def find_by_display_name(self, display_name): def find_by_display_name(self, display_name):
found = [] found = []