mirror of
https://github.com/netdata/netdata.git
synced 2025-05-05 01:30:32 +00:00

* move compression header to compression.h * prototype with zstd compression * updated capabilities * no need for resetting compression * left-over reset function * use ZSTD_compressStream() instead of ZSTD_compressStream2() for backwards compatibility * remove call to LZ4_decoderRingBufferSize() * debug signature failures * fix the buffers of lz4 * fix decoding of zstd * detect compression based on initialization; prefer ZSTD over LZ4 * allow both lz4 and zstd * initialize zstd streams * define missing ZSTD_CLEVEL_DEFAULT * log zero compressed size * debug log * flush compression buffer * add sender compression statistics * removed debugging messages * do not fail if zstd is not available * cleanup and buildinfo * fix max message size, use zstd level 1, add compressio ratio reporting * use compression level 1 * fix ratio title * better compression error logs * for backwards compatibility use buffers of COMPRESSION_MAX_CHUNK * switch to default compression level * additional streaming error conditions detection * do not expose compression stats when compression is not enabled * test for the right lz4 functions * moved lz4 and zstd to their own files * add gzip streaming compression * gzip error handling * added unittest for streaming compression * eliminate a copy of the uncompressed data during zstd compression * eliminate not needed zstd allocations * cleanup * decode gzip with Z_SYNC_FLUSH * set the decoding gzip algorithm * user configuration for compression levels and compression algorithms order * fix exclusion of not preferred compressions * remove now obsolete compression define, since gzip is always available * rename compression algorithms order in stream.conf * move common checks in compression.c * cleanup * backwards compatible error checking
15 lines
722 B
C
15 lines
722 B
C
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
#include "compression.h"
|
|
|
|
#ifndef NETDATA_STREAMING_COMPRESSION_GZIP_H
|
|
#define NETDATA_STREAMING_COMPRESSION_GZIP_H
|
|
|
|
void rrdpush_compressor_init_gzip(struct compressor_state *state);
|
|
void rrdpush_compressor_destroy_gzip(struct compressor_state *state);
|
|
size_t rrdpush_compress_gzip(struct compressor_state *state, const char *data, size_t size, const char **out);
|
|
size_t rrdpush_decompress_gzip(struct decompressor_state *state, const char *compressed_data, size_t compressed_size);
|
|
void rrdpush_decompressor_init_gzip(struct decompressor_state *state);
|
|
void rrdpush_decompressor_destroy_gzip(struct decompressor_state *state);
|
|
|
|
#endif //NETDATA_STREAMING_COMPRESSION_GZIP_H
|