Accept both PUT and POST in noded
Accept both PUT and POST in noded

This is a partial cherry-pick from
7530364ddbe949bc34fc26f25ba3f5d921beb021 on master:

Currently, noded requires PUT, even though the semantics of the RPC
calls do not match a PUT. We change the code accept both PUT and POST,
with the intention to remove the PUT support in a later version.

Additionally, we add a message to the HttpBadRequest exception to make
clear the failure mode (not seeing any error message was what made me
send this patch…). This was the only description-less use of this
exception, by the way.

Signed-off-by: Iustin Pop <acf83a5274f31a43af6b914614365999469c1a31@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
(cherry picked from commit 7530364ddbe949bc34fc26f25ba3f5d921beb021)

What was not cherry-picked is the rpc change (to switch to PUT). The
reason I want to backport this to devel-2.5 is that when upgrading to
2.6, having noded accept both makes for an easier upgrade path.

Signed-off-by: Iustin Pop <acf83a5274f31a43af6b914614365999469c1a31@google.com>
Reviewed-by: Michael Hanselmann <68b67885ff74281219b4a4be33cc20fd45078d7c@google.com>

bitemyapp/ganeti,yiannist/ganeti,mbakke/ganeti,leshchevds/ganeti,onponomarev/ganeti,bitemyapp/ganeti,mbakke/ganeti,mbakke/ganeti,leshchevds/ganeti,apyrgio/snf-ganeti,grnet/snf-ganeti,ganeti-github-testing/ganeti-test-1,ganeti-github-testing/ganeti-test-1,andir/ganeti,apyrgio/snf-ganeti,yiannist/ganeti,leshchevds/ganeti,andir/ganeti,onponomarev/ganeti,ganeti/ganeti,dimara/ganeti,andir/ganeti,ganeti/ganeti,dimara/ganeti,apyrgio/ganeti,ganeti/ganeti,yiannist/ganeti,grnet/snf-ganeti,apyrgio/ganeti