An Unexpected API Error return when call nova v3 api with not enough parameters
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Undecided
|
Ivan-Zhu |
Bug Description
when port the following test into v3:
meta = {'meta1': 'data1'}
The post body will be empty.
when the following action in server_metadata, receive the request will raise a TypeError, but expected_errors will return response with code 500. I think it should be BadRequest (code 400) like v2 api.
def update_all(self, req, server_id, body):
the following is the nova log:
2013-11-20 21:44:44.893 DEBUG routes.middleware [-] Matched PUT /servers/
2013-11-20 21:44:44.893 DEBUG routes.middleware [-] Route path: '/servers/
2013-11-20 21:44:44.894 DEBUG routes.middleware [-] Match dict: {'action': u'update_all', 'server_id': u'92875aa6-
2013-11-20 21:44:44.896 DEBUG nova.api.
2013-11-20 21:44:44.897 DEBUG nova.api.
2013-11-20 21:44:44.897 ERROR nova.api.
2013-11-20 21:44:44.897 TRACE nova.api.
2013-11-20 21:44:44.897 TRACE nova.api.
2013-11-20 21:44:44.897 TRACE nova.api.
2013-11-20 21:44:44.897 TRACE nova.api.
2013-11-20 21:44:44.897 TRACE nova.api.
2013-11-20 21:44:44.898 INFO nova.api.
<type 'exceptions.
Changed in nova: | |
assignee: | nobody → Ivan-Zhu (ivan-zhu) |
Changed in nova: | |
milestone: | none → icehouse-2 |
Changed in nova: | |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | icehouse-2 → 2014.1 |
Fix proposed to branch: master /review. openstack. org/57447
Review: https:/