dev@jsr311.java.net

Re: JSR311: gzip encoding

From: Stephan Koops <Stephan.Koops_at_web.de>
Date: Mon, 30 Mar 2009 19:45:07 +0200

Hi,

-1

If the accept-Encoding allows GZIP, than the JAX-RS runtime could decide
on its own, that it gzip the data. This it could do with all encodings,
that are allowe. So there is no additional annotation required.
Ot course the runtime must set the content-encoding header, if it encode
the data.

best regards
   Stephan

Bill Burke schrieb:
> It seems to me that most JAX-RS implementations support GZIP encoding.
> Any way we could require it within the specification? Also maybe
> define a @GZIP annotation to specify we want to encode the response
> (of course it would be sensitive to the Accept-Encoding header).
>
> In Resteasy we encode the response in GZIP if the content-encoding
> response header has been set. Our @GZIP annotation sets the
> content-encoding header.
>
> It just seems weird to me that there is no portable way of doing
> encoding within JAX-RS.