From 79a9ca6da345db454f61b82dbd761507141fbddf Mon Sep 17 00:00:00 2001 From: He Jie Xu Date: Thu, 27 Aug 2015 16:12:31 +0800 Subject: [PATCH] Add a note about the 400 response not requiring a microversion As the API validation code always return 400 when request with invalid json body, so 400 is an available status code for all the Nova API. Then no microversion bump required for fixing 500 to 400. Change-Id: I0454e95cd0655c910fad8b39ead2b5edab216b68 Related-Bug: 1471239 --- doc/source/api_microversion_dev.rst | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/doc/source/api_microversion_dev.rst b/doc/source/api_microversion_dev.rst index ab4d8e86f23e..079a9275ecc0 100644 --- a/doc/source/api_microversion_dev.rst +++ b/doc/source/api_microversion_dev.rst @@ -65,7 +65,7 @@ changed. The user contract covers many kinds of information such as: Example: an API previously could return 200, 400, 403, 404 and the change would make the API now also be allowed to return 409. - See [#f2]_ for the 403 case. + See [#f2]_ for the 400 and 403 cases. - changing a status code on a particular response @@ -154,9 +154,10 @@ we need a microversion". microversion is probably needed. .. [#f2] The exception to not needing a microversion when returning a - previously unspecified error code is the 403 case. This is considered OK to - return even if previously unspecified in the code since it's implied given - keystone authentication can fail with a 403. + previously unspecified error code is the 400 and 403 cases. This is + considered OK to return even if previously unspecified in the code since + it's implied given keystone authentication can fail with a 403 and API + validation can fail with a 400 for invalid json request body. In Code