Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
changefeedccl: Fix Kafka v2 Sink GZIP Compression Level Issue
Previously, the Kafka v2 sink could not properly handle negative compression levels due to differences in the underlying compression libraries used between the v1 and v2 sinks. The Kafka v1 sink implementation, which relies on the Sarama library, uses the klauspost/compress library that supports a compression level of -3. However, our v2 sink has transitioned to using franz-go, which utilizes the standard library's compression/gzip, and does not support the -3 level. In this update, the validation function now checks the GZIP compression range between HuffmanOnly (-2) and BestCompression (9). Fixes: #136492 Epic: none Release note (bug fix): We have resolved an issue in the Kafka v2 sink configuration within CockroachDB, where users were previously unable to set negative GZIP compression levels. Now, users can configure the CompressionLevel for the Kafka sink in the range of [-2, 9]. Please update the user guide to include the new valid GZIP compression level range of [-2, 9], where -2 enables Huffman encoding and -1 sets the default compression. `#Release note: None
- Loading branch information