compressstream-explainer icon indicating copy to clipboard operation
compressstream-explainer copied to clipboard

"deflate": is this zlib format or raw format?

Open ricea opened this issue 6 years ago • 2 comments
trafficstars

It's ambiguous whether the "deflate" format is raw or includes the zlib header and footer. It might be good to rename it--maybe "deflate-raw".

ricea avatar Sep 16 '19 05:09 ricea

Yeah, I think it makes the most sense to match HTTP Content-Encoding and have 'deflate' mean Zlib-wrapped DEFLATE (RFC1950)

Node uses 'deflateRaw' for the bare format and this sounds reasonable.

ericlaw1979 avatar Sep 16 '19 07:09 ericlaw1979

@ericlaw1979 Thanks. We settled on using "deflate" to mean "zlib" for consistency with HTTP, and will add "deflate-raw" in future to support zip and other use cases where the header and footer are unwanted.

ricea avatar Oct 02 '19 04:10 ricea