Revision 7530364d

b/lib/rpc.py
362 362
      else:
363 363
        requests[name] = \
364 364
          http.client.HttpClientRequest(str(ip), port,
365
                                        http.HTTP_PUT, str("/%s" % procedure),
365
                                        http.HTTP_POST, str("/%s" % procedure),
366 366
                                        headers=_RPC_CLIENT_HEADERS,
367 367
                                        post_data=body[name],
368 368
                                        read_timeout=read_timeout,
b/lib/server/noded.py
138 138
    """Handle a request.
139 139

  
140 140
    """
141
    if req.request_method.upper() != http.HTTP_PUT:
142
      raise http.HttpBadRequest()
141
    # FIXME: Remove HTTP_PUT in Ganeti 2.7
142
    if req.request_method.upper() not in (http.HTTP_PUT, http.HTTP_POST):
143
      raise http.HttpBadRequest("Only PUT and POST methods are supported")
143 144

  
144 145
    path = req.request_path
145 146
    if path.startswith("/"):

Also available in: Unified diff