weblogic mod_deflate

weblogic mod_deflate

am 15.12.2004 22:16:45 von scott

Has anyone been able to get WebLogic/Apache/Mod_deflate to work
together?

It apperas that when I configure compression in my weblogic.conf file
it is an all or nothing affair. That is compression works every file
that weblogic app serers send or I can turn it off completely.

The problem is PDF files don't like to get compressed to IE browsers so
I would like to enable compression on text, html, jscript and turn it
off for pdfs.

Here is a snip of the weblogic.conf file:

MatchExpression /wl/ WebLogicCluster=xxx.xxx.xxx.xxx:7701

SetOutputFilter DEFLATE
AddOutputFilterByType DEFLATE text/plain
#AddOutputFilterByType DEFLATE application/pdf
AddOutputFilterByType DEFLATE text/html text/css
application/x-javascript
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe)$ no-gzip
dont-vary


SetHandler default-handler
SetOutputFilter DEFLATE
AddOutputFilterByType DEFLATE text/plain
# AddOutputFilterByType DEFLATE application/pdf
AddOutputFilterByType DEFLATE text/html text/css
application/x-javascript


SetHandler default-handler


Note how I tried to compress PDFs.

SFF

Re: weblogic mod_deflate

am 15.12.2004 23:20:22 von HansH

"Scott" schreef in bericht
news:1103145405.297238.66950@f14g2000cwb.googlegroups.com...
> Has anyone been able to get WebLogic/Apache/Mod_deflate to work
> together?
>
> It apperas that when I configure compression in my weblogic.conf file
> it is an all or nothing affair. That is compression works every file
> that weblogic app serers send or I can turn it off completely.
>
> The problem is PDF files don't like to get compressed to IE browsers so
> I would like to enable compression on text, html, jscript and turn it
> off for pdfs.
Per http://httpd.apache.org/docs-2.0/mod/mod_deflate.html
SetOutputFilter DEFLATE
will indeed compress _all file types.

Per http://httpd.apache.org/docs-2.0/mod/core.html#addoutputfilt erbytype
use
AddOutputFilterByType DEFLATE text/plain text/html text/css

Use the file mime.types to find more types appropriate for you -within the
limitations of the various browser by brand and version-

HansH

Re: weblogic mod_deflate

am 16.12.2004 16:01:48 von scott

So what you are saying is I am diong both at once?

I shoud then get rid of SetOutputFileter Deflate DEFLATE

I should then ONLY put the lines:
AddOutput FilterByType DEFLATE

So this is a syntax error in that I am both deflating everything and
then trying to deflate specific stuff later?

Scott

Re: weblogic mod_deflate

am 16.12.2004 19:46:59 von HansH

"Scott" schreef in bericht
news:1103209308.337258.107870@c13g2000cwb.googlegroups.com.. .
>"HansH"
> > "Scott" schreef in bericht
> > news:1103145405.297238.66950@f14g2000cwb.googlegroups.com...
> > > Has anyone been able to get WebLogic/Apache/Mod_deflate to work
> > > together?
> > SetOutputFilter DEFLATE
> > will indeed compress _all file types.
> > use
> AddOutputFilterByType DEFLATE text/plain text/html text/css
> I shoud then get rid of SetOutputFileter DEFLATE
> I should then ONLY put the lines:
> AddOutput FilterByType DEFLATE
That is, without a space in AddOutputFilterByType

> So this is a syntax error in that I
Both you and WebLogic ...

> am both deflating everything and
> then trying to deflate specific stuff later?
Though IIRC Apache does not attempt to compress twice.
It should have reported the AddOutputFilterByType for being useless.

HansH

Re: weblogic mod_deflate

am 16.12.2004 20:30:22 von scott

That is what I thought, I will try it though.
It looks like Apache 2.0.x can't distinguish between streams from
WebLogic.
That is as the modules/filters load in Apache 2.0.49 it doesn't seem to
know what to do with the stream from weblogic until it is already sent.

It looks like Apache 2.2 (whenever it comes out will be a better job of
filtering)
http://httpd.apache.org/docs-2.1/mod/mod_filter.html
Do you concur? Scott

Re: weblogic mod_deflate

am 16.12.2004 22:39:15 von HansH

"Scott" schreef in bericht
news:1103225422.001713.88840@z14g2000cwz.googlegroups.com...

You should make it a habbit to leave in some of the previous post, not all
read news via a webfront.

> That is what I thought, I will try it though.
> It looks like Apache 2.0.x can't distinguish between streams from
> WebLogic.
Streams ... audio, video ...

> That is as the modules/filters load in Apache 2.0.49 it doesn't seem to
> know what to do with the stream from weblogic until it is already sent.
.... should not be compressed this way.


I do not understand what you are trying to state, please explain.


HansH

Re: weblogic mod_deflate

am 17.12.2004 17:42:45 von scott

WebLogic had a bug in how they worked with Location tags. Their SP4 to
their 8.1 Apache 2.0.xx plug-in fixes many issues. However
Mod_deflate is not one of them.

The issue seems to be that while we can log the content-type comming
from the WebLogic server mod_deflate does not seem to know what to do
with the content-type. I am presented with an either/or situation:
deflate everything or deflate nothing, I can't seem to specify what to
deflate. So this is why when we turn deflate on it works but then
corrupts PDF files.

Here is a snip of my new (working) weblogic.conf file:

BTW there are many Weblogic servers called this is just an example and
yes some are clustered.


SetHandler weblogic-handler
WebLogicHost xvhost
WebLogicPort 7070
WLExcludePathOrMimeType *.css
WLExcludePathOrMimeType *.gif
WLExcludePathOrMimeType *.js
AddOutputFilterByType DEFLATE text/* application/x-javascript

#******************************
# DEFLATE doesn't work in the location tag or below either

#AddOutputFilterByType DEFLATE text/* application/x-javascript
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe)$ no-gzip
dont-vary


SetHandler default-handler
AddOutputFilterByType DEFLATE text/* application/x-javascript


I have tried to put the AddOutPUtFilterByType in my httpd.conf or the
virtual.conf that calls the above weblogic.conf but it does not work no
matter where I put it.

I think this is either a bug in mod_deflate or in the Apache 2.0.xx
filter mechanism.

I will look at the mod_deflate home page to see if this is addressed.

I may also try to use mod_gzip in place of mod_deflate, don't know if
that is a valid way to go or not.

Any ideas welcome as I am being told that we will have to abandon
Apache for the other webserver. I would really like to not so this but
compression is a must.

Scott

Re: weblogic mod_deflate

am 17.12.2004 19:40:50 von scott

Recap: When I get dynamic content from weblogic I can't control how to
compress it with mod_deflate. I can log and therefore know what the
content-type is however. If I set SetOutputFilter DEFLATE everything
gets compressed. I need to control pdfs and not compress them.
AddOutputFilterbyType does not seem to work so I got two ideas.

Looking at the documentation I have come up with two ideas:

Configure defalte to do the following:


SetHandler weblogic-handler
WebLogicHost xvhost
WebLogicPort 7070
WLExcludePathOrMimeType *.css
WLExcludePathOrMimeType *.gif
WLExcludePathOrMimeType *.js

#******************************
# DEFLATE would not compress pdf ???

SetOutputFilter DEFLATE
RemoveOutFilter DEFLATE application/pdf
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe)$ no-gzip
dont-vary


Or try to add the pdf type in the SetEnvIfNoCase as follows:


SetHandler weblogic-handler
WebLogicHost xvhost
WebLogicPort 7070
WLExcludePathOrMimeType *.css
WLExcludePathOrMimeType *.gif
WLExcludePathOrMimeType *.js

#******************************
# DEFLATE would ignore pdf ????

SetOutputFilter DEFLATE
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe|pdf)$ no-gzip
dont-vary

Compression is absolutely needed - comments??

Scott

Re: weblogic mod_deflate

am 17.12.2004 20:27:38 von scott

More research has led me to believe to put it like this:

SetOutputFilter DEFLATE
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe)$ no-gzip
dont-vary
SetEnvIfNoCase Request_URI \.pdf$ no-gzip dont-vary

Recap: When I get dynamic content from weblogic I can't control how to
compress it with mod_deflate. I can log and therefore know what the
content-type is however. If I set SetOutputFilter DEFLATE everything
gets compressed. I need to control pdfs and not compress them.

Scott

Re: weblogic mod_deflate

am 17.12.2004 22:42:35 von scott

I got pushed back on this and told this won't work!
Has someone else done this and have it work?1? Scott

More research has led me to believe to put it like this:

SetOutputFilter DEFLATE

SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe)$ no-gzip

dont-vary

SetEnvIfNoCase Request_URI \.pdf$ no-gzip dont-vary

Recap: When I get dynamic content from weblogic I can't control how to
compress it with mod_deflate. I can log and therefore know what the
content-type is however. If I set SetOutputFilter DEFLATE everything
gets compressed. I need to control pdfs and not compress them

..

Scott

Re: weblogic mod_deflate

am 17.12.2004 22:47:53 von HansH

"Scott" schreef in bericht
news:1103308850.714698.67110@f14g2000cwb.googlegroups.com...

You should make it a habbit to leave in some of the previous post -at least
the (nick)name to whos post your respondiong- , not all read news via a
webfront.

> Recap: When I get dynamic content from weblogic I can't control how to
> compress it with mod_deflate. I can log and therefore know what the
> content-type is however. If I set SetOutputFilter DEFLATE everything
> gets compressed. I need to control pdfs and not compress them.
> AddOutputFilterbyType does not seem to work so I got two ideas.
>
> Looking at the documentation I have come up with two ideas:
>
> Configure defalte to do the following:
>
>
> SetHandler weblogic-handler
> WebLogicHost xvhost
> WebLogicPort 7070
> WLExcludePathOrMimeType *.css
> WLExcludePathOrMimeType *.gif
> WLExcludePathOrMimeType *.js
>

> #******************************
> # DEFLATE would not compress pdf ???
>
> SetOutputFilter DEFLATE
> RemoveOutFilter DEFLATE application/pdf
Setaside a typo, this directive requires an extention rather than a
mime-type 'RemoveOutputFilter pdf'

> SetOutputFilter DEFLATE
> SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe|pdf)$ no-gzip
> dont-vary

Both will only work if your request is showing .pdf as its extention ... if
your application 'suddenly' decides to dump a pdf file -even if it passes
the proper content-type header-, I guess, your troubles will persist.


BTW, is
AddOutput FilterByType DEFLATE
not working at all?


HansH

Re: weblogic mod_deflate

am 18.12.2004 03:40:34 von scott

HansH,

Short of coping and pasting stuff again I don't see a way of putting
the previous posts into my replies. I will copy and paste because I
know what you are going through. I am using Google's group function
and it works really quite well except for the posting situation.

Now to the problem, I must have spent 4-5 hours looking at docs,
tutorials and other stuff referencing this issue. It boils down to
this:

I am pretty confident that the WebLogic/Apache mix leads to this
behaviour. I am able to compress and not compress at will except
through Weblogic. BEA blames Apache's filter mechanism.

AddOutPutFilterByType simply does not work.

SetOutputfilter DEFLATE works well, except for the PDF issue.

The SetEnvIfNoCase functions as expected as I am not compressing any of
the graphics from WebLogic. Most of the docs has the 2 SetEnvIfNoCase
commands separate but I can't imagine that adding PDF to the line I
have thus:

SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe|pdf)$ no-gzip
dont-vary [This is all on one line].

Will cause me trouble and if it does I can always add it as new line.

I hope it works as I am getting a lot of static about compression, "We
really need it, etc, blah, blah"

I will let you know what BEA says and also try it out on Monday to see
if it works and appreciate bouncing the ideas off you.
Thank you and have a beverage of your choice this weekend,

Scott

Re: weblogic mod_deflate

am 18.12.2004 15:32:02 von HansH

"Scott" schreef in bericht
news:1103337634.798129.321180@z14g2000cwz.googlegroups.com.. .
> It boils down to this:
> I am pretty confident that the WebLogic/Apache mix leads to this
> behaviour. I am able to compress and not compress at will except
> through Weblogic. BEA blames Apache's filter mechanism.
By now I'm aware WebLogic is not just a bunch of CGI scripts and comes with
mod_wl. This module apparently acts like a reverse proxy with a dedicated
connection pool.

> AddOutPutFilterByType simply does not work.
That is, even using 'AddOutPutFilterByType text/html' a page of this content
type served by weblogic is sent to the browser without being compressed by
mod_deflate??

Check at your browser -FireFox with LiveHTTPheaders assumed- the
content-type header, might as wel be one of
application/xhtml+xml
application/xml
text/xml

> SetOutputfilter DEFLATE works well, except for the PDF issue.
Where the PDF issue is more browser than apache or weblogic related ...

> SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|jar|exe|pdf)$
> no-gzip dont-vary [This is all on one line].
However, if I understood these directives -seen in a previous post-
correctly ...
http://e-docs.bea.com/wls/docs81/plugins/plugin_params.html
WLExcludePathOrMimeType *.css
WLExcludePathOrMimeType *.gif
WLExcludePathOrMimeType *.js
.... reqeusts for some of the extentions in the regex are not forwarded by
mod_wl and thus the apache server is the only one controlling the response.

> I hope it works as I am getting a lot of static about compression, "We
> really need it, etc, blah, blah"
Googling the web this issue goes back to 1998 ... many have their scripts do
compression using java.util.zip.GZIPOutputStream, rather then trusting the
compression of an upfront proxy.



Twisting and bending every line to find an escape, I ran into a note
" The by-type output filters are never applied on proxy requests. "
at
http://httpd.apache.org/docs-2.0/mod/core.html#addoutputfilt erbytype

Quite disturbingly that sounds like turning an assumed bug into a _unwanted_
feature :-(

What platform are

> I will let you know what BEA says
.... advise them not to tell apache their mod_wl is a proxy ...

> and also try it out on Monday to see
> if it works and appreciate bouncing the ideas off you.
You're welkom ...

HansH

Re: weblogic mod_deflate

am 22.12.2004 19:52:13 von scott

Hello All,

I have been able to duplicate this behavior with Tomcat instead of
WebLogic.

I have cleaned up the below to hide the real server names but the
behavior is reproducable easily. Comments?

Scott

Config:

Apache-2.0.52 on Solaris-2.8 using prefork model


mod_jk proxying to backend Tomcat server.

mod_jk configured as such:

*****************
# Tomcat Configuration
LoadModule jk_module modules/mod_jk.so
JkWorkersFile /tools/tomcat/v4.1.24/conf/workers.properties
JkLogFile /tools/tomcat/v4.1.24/logs/mod_jk.log
JkLogLevel debug
JkMount /opencms/* testWorker
*****************

Apache container configured as such:

# In the LoadModules section of my config file
LoadModule deflate_module modules/mod_deflate.so

In my Virtual Server config:

*****************

ServerAdmin test@testsvr.com
DocumentRoot /tools/apache/htdocs
ServerName testsvr.com
ErrorLog logs/testsvr_log
CustomLog logs/testsvr-clickstream clickstream
AddOutputFilterByType DEFLATE text/html text/plain text/css
#SetOutputFilter DEFLATE

*****************

When I use the above settings for access my Tomcat web application and
make a request of the type:

GET /testsvr/home/ HTTP/1.0
Host: server.xxx.com
Accept-Encoding: gzip

I receive data back like this:

*****************
HTTP/1.1 200
Date: Wed, 22 Dec 2004 16:44:22 GMT
Server: OpenCms/5.0.0
Set-Cookie: Apache=172.20.110.128.1103733862842058; path=/;
domain=.testsvr.com
Set-Cookie: JSESSIONID=840A4735D6DB8011B8EAE68E5981081D; Path=/opencms
Content-Length: 23319
Connection: close
Content-Type: text/html; charset=ISO-8859-1




etc.....
*****************

No compression is turned on, even though:

- My client indicates it can support gzip
- mod_deflate has been configured to do output encoding for data of
type
text/html.

The problem appears to be how AddOutputFilterByType works on content
that is handled by another handler/filter.

If I instead out in my config file:

SetOutputFilter DEFLATE

I get compression, but on all content.

I want to compress only text/* content, and I cannot do it based on
Location,
Directory, or even URI matching expressions. I need to do it by
inspecting
the content type of the content returned from the web application.

Re: weblogic mod_deflate

am 22.12.2004 22:48:30 von HansH

"Scott" schreef in bericht
news:1103741533.544843.23680@f14g2000cwb.googlegroups.com...
> I have been able to duplicate this behavior with Tomcat instead of
> WebLogic.
>
> I have cleaned up the below to hide the real server names but the
> behavior is reproducable easily. Comments?
> Apache-2.0.52 on Solaris-2.8 using prefork model
> mod_jk proxying to backend Tomcat server.
> mod_jk configured as such:
> *****************
> # Tomcat Configuration
> LoadModule jk_module modules/mod_jk.so
> JkWorkersFile /tools/tomcat/v4.1.24/conf/workers.properties
> JkLogFile /tools/tomcat/v4.1.24/logs/mod_jk.log
> JkLogLevel debug
> JkMount /opencms/* testWorker
> *****************
> Apache container configured as such:
> # In the LoadModules section of my config file
> LoadModule deflate_module modules/mod_deflate.so
> In my Virtual Server config:
> *****************
>
> ServerAdmin test@testsvr.com
> DocumentRoot /tools/apache/htdocs
> ServerName testsvr.com
> ErrorLog logs/testsvr_log
> CustomLog logs/testsvr-clickstream clickstream
> AddOutputFilterByType DEFLATE text/html text/plain text/css
This DOES NOT take extentions AT ALL, that's AddOutputFilter.
http://httpd.apache.org/docs-2.0/mod/mod_mime.html#addoutput filter
and that is unlikely to work for a request with a query string, addressing
the same script for any content.

I ran into this note too ...
" The by-type output filters are never applied on proxy requests. " at
http://httpd.apache.org/docs-2.0/mod/core.html#addoutputfilt erbytype
IMHO this may apply to both mod_wl abd mod_jk.

Sounds quite disturbing, might turn an assumed bug of mod_deflate into a
_unwanted_
feature of mod_mime :-(

HansH

Re: weblogic mod_deflate

am 23.12.2004 17:24:43 von scott

Hans

You are correct Addoutputfilter doesn't do what we want it to do.
Thank you for your paitence!

I would like to be able to "pre-compress" the .js .txt etc and make
..gzip pre-compressed versions of the files. Then when a browser asks
for .js file but can handle .gzip it would send the compressed
version. This would only be for static content but at least that
portion of the web site would be faster. I thinks it has something to
do with Content Negotiation (e.g. like when you allow different
languages) but how to set it up for compressed files?

Scott


HansH Dec 22, 1:48 pm show options
Newsgroups: alt.apache.configuration
From: "HansH" - Find messages by this author
Date: Wed, 22 Dec 2004 22:48:30 +0100
Local: Wed, Dec 22 2004 1:48 pm
Subject: Re: weblogic mod_deflate
Reply | Reply to Author | Forward | Print | Individual Message | Show
original | Report Abuse

"Scott" schreef in bericht
news:1103741533.544843.23680@f14g2000cwb.googlegroups.com...

- Hide quoted text -
- Show quoted text -
> I have been able to duplicate this behavior with Tomcat instead of
> WebLogic.

> I have cleaned up the below to hide the real server names but the
> behavior is reproducable easily. Comments?
> Apache-2.0.52 on Solaris-2.8 using prefork model
> mod_jk proxying to backend Tomcat server.
> mod_jk configured as such:
> *****************
> # Tomcat Configuration
> LoadModule jk_module modules/mod_jk.so
> JkWorkersFile /tools/tomcat/v4.1.24/conf/workers.properties
> JkLogFile /tools/tomcat/v4.1.24/logs/mod_jk.log
> JkLogLevel debug
> JkMount /opencms/* testWorker
> *****************
> Apache container configured as such:
> # In the LoadModules section of my config file
> LoadModule deflate_module modules/mod_deflate.so
> In my Virtual Server config:
> *****************
>
> ServerAdmin t...@testsvr.com
> DocumentRoot /tools/apache/htdocs
> ServerName testsvr.com
> ErrorLog logs/testsvr_log
> CustomLog logs/testsvr-clickstream clickstream
> AddOutputFilterByType DEFLATE text/html text/plain text/css

This DOES NOT take extentions AT ALL, that's AddOutputFilter.
http://httpd.apache.org/docs-2.0/mod/mod_mime.html#addoutput filter
and that is unlikely to work for a request with a query string,
addressing
the same script for any content.

I ran into this note too ...
"
The by-type output filters are never applied on proxy requests. " at
http://httpd.apache.org/docs-2.0/mod/core.html#addoutputfilt erbytype

IMHO this may apply to both mod_wl abd mod_jk.

Sounds quite disturbing, might turn an assumed bug of mod_deflate into
a
_unwanted_
feature of mod_mime :-(

HansH

Re: weblogic mod_deflate

am 23.12.2004 19:27:36 von HansH

"Scott" schreef in bericht
news:1103819083.377843.219120@c13g2000cwb.googlegroups.com.. .
> HansH Dec 22, 1:48 pm show options
> "Scott" schreef in bericht
> news:1103741533.544843.23680@f14g2000cwb.googlegroups.com...
> > > AddOutputFilterByType DEFLATE text/html text/plain text/css
> > This DOES NOT take extentions AT ALL, that's AddOutputFilter.
> > http://httpd.apache.org/docs-2.0/mod/mod_mime.html#addoutput filter
> > and that is unlikely to work for a request with a query string,
> > addressing the same script for any content.
> > You are correct Addoutputfilter doesn't do what we want it to do.

> > I ran into this note too ...
> > "The by-type output filters are never applied on proxy requests. " at
> > http://httpd.apache.org/docs-2.0/mod/core.html#addoutputfilt erbytype
> > IMHO this may apply to both mod_wl abd mod_jk.
> > Sounds quite disturbing, might turn an assumed bug of mod_deflate into
> > into a _unwanted_ feature of mod_mime :-(

> I would like to be able to "pre-compress" the .js .txt etc and make
> .gzip pre-compressed versions of the files. Then when a browser asks
> for .js file but can handle .gzip it would send the compressed
> version. This would only be for static content but at least that
> portion of the web site would be faster.
http://search.cpan.org/~sproctor/Apache-Precompress-0.1/Prec ompress.pm

> I thinks it has something to
> do with Content Negotiation (e.g. like when you allow different
> languages) but how to set it up for compressed files?
http://search.cpan.org/~kwilliams/Apache-Compress-1.005/Comp ress.pm

No warranties, enjoy :-(

HansH

Re: weblogic mod_deflate

am 27.12.2004 19:40:18 von scott

HansH,

Perl?!? Not what I was looking for. Believe it or not there is not
ONE example I can find after 8+ hours looking at the available
documentation. Every document, tutorial, sample file I come accross
uses multiple languages as the example. For some reason I can't seem
to get my head around the process. Very furstrating!

Here is what I want to do: I will compress every .css, .js file with
gzip so in each location there will be:

foo.css foo.css.gz foo.js foo.js.gz

What I need to do now is figure out how to get an Apache .var file that
will allow Apache to serve the *.gz file to browsers that can handle
it and *.js to browsers that can't.

I might try to setup the Multiview options since each location will
defintely have each of the above files. I know this will work and get
a vague idea of how to do it with the examples based on multiple
languages but I really need a few pointers to translate the concepts
to compressed files.

Everyone here is convinced that compressing the files will save so much
bandwidth that the work of scripting the compression and configuring
Apache is small compared to the savings. Not so sure about that but I
am not in a position to argue.

Either way is fine by me - multiview or .var file but which is better?
Comments, as always are welcome by anyone reading this,

Scott

Re: weblogic mod_deflate

am 28.12.2004 01:57:59 von HansH

"Scott" schreef in bericht
news:1104172818.941292.20620@f14g2000cwb.googlegroups.com...
>> I would like to be able to "pre-compress" the .js .txt etc and make
>> .gzip pre-compressed versions of the files. Then when a browser asks
>> for .js file but can handle .gzip it would send the compressed
>> version. This would only be for static content but at least that
>> portion of the web site would be faster.
>http://search.cpan.org/~sproctor/Apache-Precompress-0.1/Pre compress.pm

>> I thinks it has something to
>> do with Content Negotiation (e.g. like when you allow different
>> languages) but how to set it up for compressed files?
>http://search.cpan.org/~kwilliams/Apache-Compress-1.005/Com press.pm

> Perl?!? Not what I was looking for.
You need a job done, so response comes in any taste ;-)

> Believe it or not there is not
> ONE example I can find after 8+ hours looking at the available
> documentation. Every document, tutorial, sample file I come accross
> uses multiple languages as the example. For some reason I can't seem
> to get my head around the process. Very furstrating!

> Here is what I want to do: I will compress every .css, .js file with
> gzip so in each location there will be:
> foo.css foo.css.gz foo.js foo.js.gz
>
> What I need to do now is figure out how to get an Apache .var file that
> will allow Apache to serve the *.gz file to browsers that can handle
> it and *.js to browsers that can't.
>
> I might try to setup the Multiview options since each location will
> defintely have each of the above files. I know this will work and get
> a vague idea of how to do it with the examples based on multiple
> languages but I really need a few pointers to translate the concepts
> to compressed files.
>
> Everyone here is convinced that compressing the files will save so much
> bandwidth that the work of scripting the compression
OT: have a 1000 row 20 column table in doing a ration of 15..20

Scripting is at the weblogic end ... there will be a gzip library for java
somewhere, perhaps even here:
http://ftpna2.bea.com/pub/downloads/Gzipfilter_war.zip
" Gzip Filter
A Servlet 2.3 filter which compresses the response stream using gzip. This
decreases the number of bytes transferred across the network for requests
which are able to accept gzip encoding. "
and a snippet of its readme
"Map all resources which can benefit from compression such as .txt, .log,
..html and .htm. You can also use the filter to compress output from jsps and
other dynamic content."

> and configuring Apache is small compared to the savings.
> Not so sure about that but I am not in a position to argue.
But for the 'will not gzip proxied requests'...
.... and then who cares if java did that job already

> Either way is fine by me - multiview or .var file but which is better?
You won't like to maintain 3 files as a set:
> foo.css foo.css.gz foo.css.var

However, I have some bad fealings about this ...
.... IMHO you're about to mix (up) Content-Encoding and transport encoding

BTW, where do the static files reside: at Apache's or at Weblogic's?



HansH