Metastarx opened a new pull request, #11449: URL: https://github.com/apache/rocketmq/pull/11449
### Which Issue(s) This PR Fixes - Fixes #11448 ### Brief Description RocketMQ could already compress message bodies with LZ4, ZSTD and ZLIB, but all three need a third-party library or produce framing that external tools do not read by default. This change adds GZIP as a fourth selectable codec, implemented purely with java.util.zip, so a compressed body is interchangeable with the gzip output that other languages and command line tools produce. The enum, the compressor factory, the system flag bit 4 and the producer's compression-type plumbing are all extended, and the new GzipCompressor follows the same structure as the existing codecs, including level handling through the inherited Deflater and the same stream shutdown and error propagation. Existing behaviour is untouched: ZLIB stays the default, value 0 still resolves to ZLIB, and value 4 now maps to GZIP inside the three bits the system flag already reserves. ### How Did You Test This Change? `mvn test -pl client,common` - passed (Tests run: 604, Failures: 0, Errors: 0, Skipped: 8) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
