标签:server compress false img ups encoding 配置 cut prot
tomcat安装后,可以对其进行优化,提高性能:
优化前:
优化后:
优化代码:配置文件 server.xml
<Connector port="8080" URIEncoding="UTF-8" acceptCount="600" connectionTimeout="20000" enableLookups="false" executor="tomcatThreadPool" maxProcessors="1200" minProcessors="300" protocol="org.apache.coyote.http11.Http11NioProtocol" redirectPort="8443" compression="on"
compressableMimeType="text/html,text/xml,application/javascript,text/css,text/plain,image/gif, image/jpg,image/png,image/bmp" compressionMinSize="2048" noCompressionUserAgents="gozilla, traviata" useSendfile="false"/>
<Executor maxIdleTime="300000" maxSpareThreads="1200" maxThreads="1200" minSpareThreads="200" name="tomcatThreadPool" namePrefix="catalina-exec-"/>
<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" keystoreFile="/app/tomcat/tomcat.keystore" keystorePass="123456"/>
标签:server compress false img ups encoding 配置 cut prot
原文地址:https://www.cnblogs.com/tigergaonotes/p/11073899.html