POSTing to /servers with a content-type of text/plain
and a text/plain body results in a response code of 400.
It should be 415. I found this line in the code that
appears to handle this singular case and modified
the HTTP exception used to the correct one. Tests were
also updated accordingly.
Change-Id: I5fa1fdba56803b2ef63b1efaaeeced6ceb7779d9
Closes-Bug: 1567977
(cherry picked from commit a7019a87ba696509d825c6c6f2220331e4ffb033)
Reviewed: https:/ /review. openstack. org/308474 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=d627ae85261 8fff9eebfc27fdf 73287e45b1a7c7
Committed: https:/
Submitter: Jenkins
Branch: stable/mitaka
commit d627ae852618fff 9eebfc27fdf7328 7e45b1a7c7
Author: Brandon Irizarry <email address hidden>
Date: Wed Apr 13 05:18:25 2016 +0000
Changed an HTTP exception to return proper code
POSTing to /servers with a content-type of text/plain
and a text/plain body results in a response code of 400.
It should be 415. I found this line in the code that
appears to handle this singular case and modified
the HTTP exception used to the correct one. Tests were
also updated accordingly.
Change-Id: I5fa1fdba56803b 2ef63b1efaaeece d6ceb7779d9 9d825c6c6f22203 31e4ffb033)
Closes-Bug: 1567977
(cherry picked from commit a7019a87ba69650