Skip to content

Compresses a stream of bytes using lz4 compression.

compress_lz4 [level=int]

The compress_lz4 operator compresses bytes in a pipeline incrementally.

The compression level to use. The supported values depend on the codec used. If omitted, the default level for the codec is used.

Export all events in a Lz4-compressed NDJSON file

Section titled “Export all events in a Lz4-compressed NDJSON file”
export
to_file "/tmp/backup.json.lz4" {
write_ndjson
compress_lz4
}
from_file "in.lz4" {
decompress_lz4
read_ndjson
}
to_file "out.lz4" {
write_ndjson
compress_lz4 level=18
}

Last updated: