In a servelt application, I've added a Gzip filter (/*, REQUEST) and config it be the first in the filter chain. It works fine with Sitemesh's filter (/*, REQUEST, FORWARD) except that when the request is excluded as specified in deocorators.xml (e.g. for ajax request), the gzip filter throws an illegal state.
The gzip filter comes from http://jsp.codefetch.com/example/54/CompressionFilter/src/CompressionResponseWrapper.java