We looked at the Compression filter; now let’s take a look at the wrapper it uses. This is one of the most complicated topics in all of servlet-dom, so don’t panic if you don’t grok it the first time.
This response wrapper decorates the original response object by adding a compression decorator on the original servlet output stream.