tomcat|Tomcat启用GZIP,tomcat6和7的不同之处

不知道是什么原因,tomcat7将javascript的contentType变成了application/javascript,而在tomcat6以及之前的版本,从来都是text/javasctript.
下面是两个版本tomcat启用GZIP的配置信息:
tomcat6的配置:


compression="on"
compressionMinSize="50" noCompressionUserAgents="gozilla, traviata"
compressableMimeType="text/html,text/xml,text/javascript,text/css,text/plain"/>



tomcat7的配置:

compression="on"
compressionMinSize="50" noCompressionUserAgents="gozilla, traviata"
compressableMimeType="text/html,text/xml,application/javascript,text/css,text/plain"/>

    推荐阅读