illegalArgumentException:Invalid character found in method name. HTTP method names must be tokens异常

某天查询程序运行情况,发现后台报了一个错误信息如下:

 

 1 INFO: Error parsing HTTP request header
 2  Note: further occurrences of HTTP header parsing errors will be logged at DEBUG level.
 3 java.lang.IllegalArgumentException: Invalid character found in method name. HTTP method names must be tokens
 4     at org.apache.coyote.http11.InternalNioInputBuffer.parseRequestLine(InternalNioInputBuffer.java:266)
 5     at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:996)
 6     at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:623)
 7     at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1756)
 8     at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1715)
 9     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
10     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
11     at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
12     at java.lang.Thread.run(Thread.java:724)

经过网上的查询, 说是 本是http的请求 错误使用https方式请求 就会报该错,于是测试了一下,果真如此!

posted @ 2018-01-04 09:55  Nico-luo  阅读(828)  评论(0)    收藏  举报