pub enum CompressionAlgorithm {
Zstd,
Lz4,
Brotli,
Deflate,
Gzip,
}Expand description
Compression algorithms available for WAL file rotation
Variants§
Zstd
Zstandard compression: Best overall choice for WAL files. Provides excellent compression ratio (better than gzip) with fast compression/decompression speeds. Ideal for production environments where storage space is important but performance is critical. Recommended for most use cases.
Lz4
LZ4 compression: Fastest compression and decompression. Lower compression ratio than Zstd but very fast. Suitable for high-throughput environments where speed is more important than compression ratio. Good for real-time systems with limited CPU resources.
Brotli
Brotli compression: Highest compression ratio. Slower than Zstd but achieves better compression. Best for archival or low-frequency rotation scenarios where maximum compression is desired. Use when storage space is at a premium and compression time is not critical.
Deflate
DEFLATE compression: Standard compression algorithm. Balanced performance with good compatibility. Suitable for environments requiring standard compression formats. Good default for general-purpose use.
Gzip
GZIP compression: DEFLATE with gzip header. Widely compatible and standard for many systems. Slightly slower than DEFLATE due to header overhead. Use when compatibility with existing gzip tools is required.
Trait Implementations§
Source§impl Clone for CompressionAlgorithm
impl Clone for CompressionAlgorithm
Source§fn clone(&self) -> CompressionAlgorithm
fn clone(&self) -> CompressionAlgorithm
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more