码迷,mamicode.com
首页 > Web开发 > 详细

解决:Invalid character found in method name. HTTP method names must be tokens

时间:2017-03-04 15:30:30      阅读:385      评论:0      收藏:0      [点我收藏+]

标签:back   server   eth   org   ade   executor   utf-8   line   lin   

 

技术分享

阿里云上弄了一个tomcat,经常半夜发送崩溃,查看日志发现这个东西,查阅资料发现是Tomcat的header缓冲区大小不够,只需要在server.xml中增加maxHttpHeaderSize字段即可:

<Connector URIEncoding="UTF-8" port="8080" protocol="org.apache.coyote.http11.Http11NioProtocol"
	useBodyEncodingForURI="false"
	enableLookups="false"
               connectionTimeout="20000"
               redirectPort="8443" maxHttpHeaderSize="你想要的大小"/>
如:

   <Connector port="8080" executor="tomcatThreadPool"
     protocol="HTTP/1.1"
     maxThreads="1000"
     maxHttpHeaderSize="8192"
     minSpareThreads="100"
     maxSpareThreads="200"
     acceptCount="1000"
     maxConnections="1000"
     connectionTimeout="30000"
     keepAliveTimeout="15000"
     maxKeepAliveRequests="1"
      tcpNoDelay="true"
     redirectPort="8443"
     enableLookups="false"
     URIEncoding="UTF-8"/>

解决:Invalid character found in method name. HTTP method names must be tokens

标签:back   server   eth   org   ade   executor   utf-8   line   lin   

原文地址:http://www.cnblogs.com/yuananyun/p/6501324.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!