Hi André,

no.  I think Chris was semantically correct with
"[big enough to exceed your file size]"

Unfortunately, his answer had nothing to do with my posting.

Mark Thomas hit the nail on the head though:
http://tomcat.markmail.org/message/zptxhevgzkpr7if2

All the best,
DaveLaw

On 29/12/2013 14:10, André Warnier wrote:
Christopher Schultz wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

David,

On 12/28/13, 12:06 PM, David Law wrote:
Tomcat doesn't seem to serve compressed SVG's (*.svgz) correctly. The response should have a Content-Encoding header, value 'gzip'.

Any chance of getting this at long last? (a change to
org.apache.catalina.servlets.DefaultServlet, I presume)

Version: 7.0.47

What type of data do you have on the disk? What content-type? What
content-type and content-encoding are sent to the browser?

Tomcat's DefaultServlet should serve any file using gzip (with an
appropriate content-encoding) that matches the configured mime types
and isn't smaller than a certain size. All of these can be configured
with the compression, compressableMimeType, and compressionMinSize
attributes on your <Connector>. Note that use of sendFile precludes
the use of gzip compression, so if you are using sendFile you aren't
going to get that kind of encoding.

- From a stock Tomcat install, to get .svg files served using
content-encoding:gzip, you'd need to modify your <Connector> to have
the following attributes:

   compression="on"
   compressableMimeType="...., image/svg+xml"
   compressionMinSize="[big enough to exceed your file size"

I believe that this should be instead : [small enough to *not* exceed you file size].
No ?

   sendFile="false" (if appropriate)



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to