yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #57240
[Bug 1629110] [NEW] update-volume API should return BadRequest response if specified volume with request body is not existent
Public bug reported:
As the following part of API-WG guidline[1],
If a request contains a reference to a nonexistent resource in the
body (not URI), the code should be 400 Bad Request. Do not use 404
NotFound because :rfc:`7231#section-6.5.4` (section 6.5.4) mentions
the origin server did not find a current representation for the
target resource for 404 and representation for the target resource
means a URI
Nova should return a BadRequest response if specified resource with request body is not existent.
However, update-volume API returns a NotFound response instead.
That is a common mistake on REST API and we need to change it to BadRequest.
[1]: https://github.com/openstack/api-wg/blob/master/guidelines/http.rst
#failure-code-clarifications
** Affects: nova
Importance: Undecided
Assignee: Ken'ichi Ohmichi (oomichi)
Status: In Progress
** Changed in: nova
Assignee: (unassigned) => Ken'ichi Ohmichi (oomichi)
** Changed in: nova
Status: New => In Progress
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1629110
Title:
update-volume API should return BadRequest response if specified
volume with request body is not existent
Status in OpenStack Compute (nova):
In Progress
Bug description:
As the following part of API-WG guidline[1],
If a request contains a reference to a nonexistent resource in the
body (not URI), the code should be 400 Bad Request. Do not use 404
NotFound because :rfc:`7231#section-6.5.4` (section 6.5.4) mentions
the origin server did not find a current representation for the
target resource for 404 and representation for the target resource
means a URI
Nova should return a BadRequest response if specified resource with request body is not existent.
However, update-volume API returns a NotFound response instead.
That is a common mistake on REST API and we need to change it to BadRequest.
[1]: https://github.com/openstack/api-
wg/blob/master/guidelines/http.rst#failure-code-clarifications
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1629110/+subscriptions
Follow ups