I have a rest api for delete as RequestMethod.DELETE.
I have the @PathVariable("mediaId") String mediaId.
When I invoke the api with out a path paramert value as below, I get 405 Method Not Allowed.
http://localhost:8080/myservice/deleteme/mediaId/
The definition of 405 in wiki as below,
405 Method Not Allowed A request method is not supported for the requested resource; for example, a GET request on a form which requires data to be presented via POST, or a PUT request on a read-only resource.
Since i use the correct http method DELETE to invoke the delete api, why I am getting 405? In my opinion, 400 is more valid?