Spring WARNING: "HEAD" request method is not supported

I get a warning message per second after a successful deployment on tomcat 7:

org.springframework.web.servlet.PageNotFound handleHttpRequestMethodNotSupported WARNING: "HEAD" request method is not supported

but the application . How to avoid this annoying message?

+6
source share
2 answers

This is an IntelliJ IDEA bug

β†’ see the problem

it will be fixed in the next version and until the patch is created. Download link

Close the idea and replace the next file with the downloaded one (before backing up the source file)

<idea home>/plugins/JavaEE/lib/javaee-impl.jar

+8
source

You will need to add the following @RequestMapping(method = {RequestMethod.GET, RequestMethod.HEAD}) to your methods that do not work. This will allow them to process HEAD requests and raise a warning.

+9
source

Source: https://habr.com/ru/post/982544/


All Articles