netty5/codec
Chris Vest 98e3605d4d
Make all compression codecs support buffers that don't have arrays (#11383)
Motivation:
Various compression codecs are currently hard-coded to only support buffers that are backed by byte-arrays that they are willing to expose.
This is efficient for most of the codecs, but compatibility suffers, as we are not able to freely choose our buffer implementations when compression codecs are involved.

Modification:
Add code to the compression codecs, that allow them to handle buffers that don't have arrays.
For many of the codecs, this unfortunately involves allocating temporary byte-arrays, and copying back-and-forth.
We have to do it that way since some codecs can _only_ work with byte-arrays.
Also add tests to verify that this works.

Result:
It is now possible to use all of our compression codecs with both on-heap and off-heap buffers.
The default buffer choice has not changed, however, so performance should be unaffected.
2021-06-14 10:55:35 +02:00
..
src Make all compression codecs support buffers that don't have arrays (#11383) 2021-06-14 10:55:35 +02:00
pom.xml Introduce BrotliDecoder (#10960) 2021-05-10 15:39:01 +02:00