You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
功能说明:Adds GZIP as a selectable message body compression codec alongside the existing LZ4, ZSTD and ZLIB codecs. GZIP is implemented entirely with the JDK (java.util.zip.GZIPOutputStream / GZIPInputStream), so no new dependency, LICENSE entry or IP clearance is required, and its framing is what nearly every other language and command line tool produces by default, which makes compressed payloads interchangeable with external producers and consumers. It mirrors the existing codec family exactly.
Feasibility: Feasible — straightforward addition Scope:common/compression module (4 core files + tests) Compatibility: Forward-compat risk for older clients/brokers (same as when ZSTD was added)
The existing compression infrastructure (CompressionType enum, Compressor interface, CompressorFactory) is well-designed for extension. Adding GZIP requires:
New GzipCompressor.java implementing Compressor (JDK GZIPOutputStream/GZIPInputStream — zero new dependencies)
Add GZIP(4) to CompressionType enum + MessageSysFlag constant
Register in CompressorFactory
Tests
No changes needed in client/broker/store layers — producer resolves via CompressionType.of() + getCompressionFlag(), consumer decompresses via MessageDecoder/factory, broker stores opaque bytes.
Concerns:
Older clients/brokers will throw RuntimeException on unknown compression type value 4 (same forward-compat pattern as ZSTD addition)
GZIP offers weaker ratio/speed than ZSTD/LZ4 — primary value is ecosystem interoperability (standard format supported by virtually every language/tool)
Overall a clean, low-risk enhancement if the interop benefit is desired.
Activity
RockteMQ-AI commentedon Oct 16, 2026
Issue Evaluation
Category:
type/enhancement| Status: EvaluatedFeasibility: Feasible — straightforward addition
Scope:
common/compressionmodule (4 core files + tests)Compatibility: Forward-compat risk for older clients/brokers (same as when ZSTD was added)
The existing compression infrastructure (
CompressionTypeenum,Compressorinterface,CompressorFactory) is well-designed for extension. Adding GZIP requires:GzipCompressor.javaimplementingCompressor(JDKGZIPOutputStream/GZIPInputStream— zero new dependencies)GZIP(4)toCompressionTypeenum +MessageSysFlagconstantCompressorFactoryNo changes needed in client/broker/store layers — producer resolves via
CompressionType.of()+getCompressionFlag(), consumer decompresses viaMessageDecoder/factory, broker stores opaque bytes.Concerns:
RuntimeExceptionon unknown compression type value 4 (same forward-compat pattern as ZSTD addition)Overall a clean, low-risk enhancement if the interop benefit is desired.
Automated evaluation by github-manager-bot