0
是否可以爲https:和同時啓用gzip壓縮來配置Tomcat(7.075)?我無法弄清server.xml中http連接器屬性的有效組合,以完成工作。四個與壓縮相關的屬性可用於http:使用https可能的Tomcat進行gzip壓縮
compression="on"
compressableMimeType="application/json"
compressionMinSize="8192"
useSendfile="false"
在配置https時似乎沒有任何影響。我目前的配置:
<Connector port="8443"
protocol="HTTP/1.1"
SSLEnabled="true"
maxThreads="50"
server="web"
allowTrace="false"
keystoreFile="/app/certs/keystore.jks"
keystorePass="********"
scheme="https"
secure="true"
clientAuth="false"
sslProtocol="TLS"
sslEnabledProtocols="TLSv1.1,TLSv1.2"
ciphers="TLS_..._SHA"
maxKeepAliveRequests="100"
connectionTimeout="20000"
compression="on"
compressableMimeType="application/json"
compressionMinSize="8192"
useSendfile="false"
maxSwallowSize="-1"
socket.soKeepAlive="true"/>
相關https://stackoverflow.com/questions/2767211/can-you-use-gzip-over-ssl-and-connection-keep-alive-headers – Hackerman