1

I have a website running on a server with Tomcat (port 8080) and IIS (6). I've implemented the webutilities filter from Google (to minify resource files) and added it to the web.xml file of my project (WEB-INF/web.xml).

When I access a resource-file (JS / CSS) on my website from a browser (through IIS), it shows that it was not minified. However, when I access it directly through Tomcat (port 8080) it shows up as minified.

This tells me that the filter I added in the web.xml file in fact works, but for some reason IIS or ISAPI must be somehow blocking the minification. Is this possible?

Any advice on how to fix this would be greatly appreciated. Thank you!

sempervirescent
  • 153
  • 1
  • 8
  • can you post some code of how you implemented the 'webutilities'? – ndequeker Oct 30 '13 at 19:13
  • I did everything according to this page: https://code.google.com/p/webutilities/ then added all the filters: https://code.google.com/p/webutilities/wiki/ChainingOrder after which I got all sorts of errors with missing libraries, found those and added them as well. Eventually got no errors, and when I look at the page at port :80 (Tomcat) I can see the file minified. If I specify no port and it goes through IIS, the minification is not there. – sempervirescent Oct 30 '13 at 19:51

1 Answers1

0

In case this will help anyone else.

If Tomcat was in charge of transport (when I access it at port 8080), Tomcat does the compression/minification and it works fine. But when Tomcat is proxied by IIS, then IIS will be responsible for minification, and all Tomcat settings as far as minification are useless.

I still need to find a way to have IIS minify the files, and I was not able to find it yet. Seems that all recommended solutions are for .ASP pages, and I use Java and .JSP. So I am not sure how to do that yet, but as far as this post, I believe it's all clear.

Thanks!

sempervirescent
  • 153
  • 1
  • 8