zun REST API incorrectly says 500 when client incorrectly creates container with nets as an array of strings
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zun |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Below I show an HTTP request and response message with status code 500. The response message does not say what the error is and I could not find anything related to this in the systemd journals for zun-api, zun-wsproxy, kuryr-libnetwork, or zun-compute.
Please change the following response from 500 to 400.
Please also change the error message to something like "Error: nets should be an array of objects instead of an array of strings."
Thanks.
POST /v1/containers?
Host: pdv-packstack-
Content-Length: 216
Accept-Encoding: gzip, deflate
Accept: */*
User-Agent: python-
OpenStack-
Connection: keep-alive
X-Auth-Token: gAAAAABbwR8539f
Content-Type: application/json
{"name": "nto_client5", "image": "nto_client", "command": "dumb-init install/
Openstack-
Openstack-
Openstack-
Vary: OpenStack-
Content-Type: application/json
Content-Length: 261
X-Openstack-
Date: Fri, 12 Oct 2018 22:24:58 GMT
Connection: keep-alive
{"errors": [{"status": 500, "code": "container.", "links": [], "title": "Internal Server Error", "detail": "Your request could not be handled because of a problem in the server. Error Correlation id is: a28d8d23-
Changed in zun: | |
status: | New → Triaged |
importance: | Undecided → Medium |
Changed in zun: | |
status: | Triaged → Fix Released |
Fix proposed to branch: stable/queens /review. openstack. org/610282
Review: https:/