Skip to main content

compress_for_speed

Function compress_for_speed 

Source
pub fn compress_for_speed(input: &[u8]) -> Result<BytesGatherer>
Expand description

Compress using lz4 (fast). Use for RPC wire transfer.

Falls back to verbatim (version 0) if:

  • input is below the minimum threshold, or
  • the compressed form would not be smaller than the original.