3 Mart 2011 Perşembe

How to enable gzip compression for Tomcat?.

You should edit server.xml which is located under conf directory of tomcat installation.
You should add these attributes to connector element.


compression="on" compressableMimeTypes="text/html,text/xml,text/javascript,text/css"



After the modification connector element would be like this ;

<8080" protocol="HTTP/1.1" 
connectionTimeout="20000" redirectPort="8443"
compression="on" compressableMimeTypes="text/html,text/xml,
text/javascript,text/css"/>

Hiç yorum yok:

Yorum Gönder