Invalid character found in the HTTP protocol

Issue

  • The tomcat server is fully started, however for some reason, it's shutting down after some minutes with the below error
    INFO [http-nio-8080-exec-7] org.apache.coyote.http11.Http11Processor.service Error parsing HTTP request header
    Note: further occurrences of HTTP request parsing errors will be logged at DEBUG level.
    java.lang.IllegalArgumentException: Invalid character found in the HTTP protocol
    at org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:517)
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:291)
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:754)
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1376)
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:748)

Environment

  • Tomcat
  • Liferay DXP 7.0 - 7.4

Resolution

  • The default allocated port number (8080) might have expired and that results in the server being unreachable. Checking the port number availability might help.
  • Also, there is a chance that HTTPS requests from clients on an endpoint that isn't HTTPS enabled.
这篇文章有帮助吗?
0 人中有 0 人觉得有帮助