-
Bug
-
Resolution: Done
-
Major
-
2.3.2.Final, 2.3.1
-
None
For the example below, if the method is invoked with Accept-Encoding:gzip, then the value of Content-Length sent back is 11 (which is the length of "Hello World" uncompressed).
@Path("reports") class Test { @GET @GZIP Response helloWorld() { try { return Response.ok("Hello World".getBytes("ISO-8859-1")).type(MediaType.TEXT_PLAIN).build(); } catch (UnsupportedEncodingException e) { throw new AssertionError(e); } } }
If the entity were a String, then the value of Content-Length sent is correct (31).
@Path("reports") class Test { @GET @GZIP Response helloWorld() { return Response.ok("Hello World").type(MediaType.TEXT_PLAIN).build(); } }