I am using Spring Boot to write a simple controller. I am trying Put, Post methods from Postman.
@RequestMapping(path="/formData", method=RequestMethod.POST)
public String processPostFormData() {
return "practice/PutPage";
}
@RequestMapping(path="/formData", method=RequestMethod.PUT)
public String processPutFormData() {
return "practice/PutPage";
}
Post works as expected, but Put gives me the following response body:
"status": 405, "error": "Method Not Allowed", "message": "JSPs only permit GET POST or HEAD"
Also, csrf().disable()
is set in the subclass of WebSecurityConfigurerAdapter.
How can this issue be resolved?