compressWithStats

Compress and return both the wire payload and intermediate sizes for reporting.

Throws

if the underlying zstd codec fails to compress.