Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jersey-dev] Question about GZIP encoding and Content-Length

Hi all,

I'm not sure how Jersey handles the Content-Length header when a response is GZIP-compressed (via GZipEncoder for example). I see in my tests that a Content-Length header is (sometimes) sent but it is different from the actual body length. I believe that's not OK as the two numbers should match. So can someone explain to me two things:

1) why is Content-Length sometimes sent and sometimes not? What does it depend on? 2) why is Content-Length different from the actual body length when GZIP encoding is used.

Thanks in advance,
Boris



Back to the top