File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Tomcat and the fly likes mod_deflate doesn't work Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "mod_deflate doesn Watch "mod_deflate doesn New topic

mod_deflate doesn't work

Rudy Rusli
Ranch Hand

Joined: Jun 01, 2006
Posts: 114
I put this line below in httpd.conf:

It doesn't work. It supposed to gzip the page that I'm requesting through Apache, right?
Is this the only thing I have to do to use the DEFLATE filtering capability?

Thanks in advance for the help.
Rudy Rusli
Ranch Hand

Joined: Jun 01, 2006
Posts: 114
This below is more detail explanation for my question. Sorry I wasn't giving too much detail previously.
I'm trying to compress content before it is delivered to the client.
So I follow the instructions on this link:

I add these two lines on my httpd.conf:
AddOutputFilterByType DEFLATE text/html text/plain text/xml
SetOutputFilter DEFLATE

Then I restart Apache.

Then I try to access a JSP page that generates XML page using web browsers. But it seems that the DEFLATE filter doesn't do anything. I'm not sure what did I do wrong? Am I missing some important steps here?

Thanks in advance for the help.
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13036
Im not real clear on your configuration, but Tomcat can handle compression of response streams through servlet filters. A google search for "servlet filter gzip" will turn up lots of hits.

I agree. Here's the link:
subject: mod_deflate doesn't work
It's not a secret anymore!