Bug 1979044

Summary: Designate DNS - “BadRequest” is not raised for set quota, If some quota value is invalid.
Product: Red Hat OpenStack Reporter: Arkady Shtempler <ashtempl>
Component: openstack-designateAssignee: Michael Johnson <michjohn>
Status: CLOSED ERRATA QA Contact: Toni Freger <tfreger>
Severity: medium Docs Contact:
Priority: medium    
Version: 17.0 (Wallaby)CC: jschluet, michjohn, njohnston, scohen
Target Milestone: gaKeywords: Triaged
Target Release: 17.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: openstack-designate-12.0.2-0.20220529170342.2e55c3e.el9ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-09-21 12:16:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Arkady Shtempler 2021-07-04 13:48:32 UTC
Scenario:
Try to set quota for a project using invalid quotas, for example:

2021-07-04 16:42:13.331 1169274 INFO tempest.lib.common.rest_client [req-036ef900-3e94-4821-9633-be79f88ceddc ] Request (QuotasV2Test:test_admin_sets_invalid_quota_values): 500 PATCH http://10.35.64.8/dns/v2/quotas/81f5b609f64e40799aad57228c6bec6c 0.321s
2021-07-04 16:42:13.332 1169274 DEBUG tempest.lib.common.rest_client [req-036ef900-3e94-4821-9633-be79f88ceddc ] Request - Headers: {'X-Auth-All-Projects': True, 'content-type': 'application/json', 'X-Auth-Token': '<omitted>'}
        Body: {"zones": "tempest-1326507445", "zone_records": 468095, "zone_recordsets": 307092, "recordset_records": 498799, "api_export_size": 968527}

Actual result:
500 Unknown is raised:
    Response - Headers: {'date': 'Sun, 04 Jul 2021 13:42:13 GMT', 'server': 'Apache/2.4.41 (Ubuntu)', 'content-length': '90', 'x-openstack-request-id': 'req-036ef900-3e94-4821-9633-be79f88ceddc', 'connection': 'close', 'content-type': 'application/json', 'status': '500', 'content-location': 'http://10.35.64.8/dns/v2/quotas/81f5b609f64e40799aad57228c6bec6c'}
        Body: b'{"code": 500, "type": "unknown", "request_id": "req-036ef900-3e94-4821-9633-be79f88ceddc"}' _log_request_full /opt/stack/tempest/tempest/lib/common/rest_client.py:450

Expected result:
400 Bad Request with proper Error message.

Comment 10 errata-xmlrpc 2022-09-21 12:16:04 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Release of components for Red Hat OpenStack Platform 17.0 (Wallaby)), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2022:6543