• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problems with Compression Servlet Filter

 
Reema Patel
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All,
I have a simple requirement, I want to compress the response contents. I'm using a filter, wherein I first check if the browser supports zipping. I'm also printing debugging statements inside the write() method, they are getting printed but the problem is that I don't get to see anything on the page (its blank).

Pls. help..
Here is the code...

Filter Code




Customized Response Wrapper Code


The problem is that i'm getting a blank page.
I have tried to run on IE 6 and Mozilla 5.0 and I'm using Tomcat 5 at the web container.

Thanks,
Reema

[ August 07, 2006: Message edited by: Reema Patel ]
[ August 07, 2006: Message edited by: Reema Patel ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65229
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please use UBB code tags when posting more than one line of code.
 
Reema Patel
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[Thread hi-jack removed. Reema, please ask your questions in your own topics that you open. Do not hi-jack other people's topics.]
[ August 08, 2006: Message edited by: Bear Bibeault ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tomcat has compression built in.
You just have to turn it on.

Look for the "compression" attribute in this http connector config page:
http://tomcat.apache.org/tomcat-5.5-doc/config/http.html
 
Reema Patel
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey,
I can now run the filter code on BEA WLS, but the problem is that it is showing junk text. Also, ironically the filter mechanism is taking along time.
Reema
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Reema Patel:
Hey,
I can now run the filter code on BEA WLS, but the problem is that it is showing junk text. Also, ironically the filter mechanism is taking along time.
Reema



I thought you said you were using Tomcat. ? .
[ August 11, 2006: Message edited by: Ben Souther ]
 
Reema Patel
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI Ben,
Thanks for the post.
Earlier I used Tomcat 5.
This time I'm using WLS 8

Thanks,
Reema
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic