Question:
Using CkHttp or CkRest, how can one get the compressed body (before being decompressed) of a gzipped response?
Unfortunately, it's not possible..
Maybe it's possible with CkRest -- I'll have to see. Auto-decompression is too enmeshed in the guts of CkHttp to warrant trying to add the feature, but maybe CkRest is easier. I can't make any promises here, as there's so much to do already..
It would be great if it could be possible with CkRest. One major use case for this is for instance when forwarding or caching the response in its already-compressed form, because this would eliminate the need for another (unnecessary) compression.
Maybe it could be something like a
bool ReadRespBodyBinary(CkByteData &outBytes, bool Raw);
method in CkRest where Raw
could specify getting the body without decompression applied to it.