RocksDict
RocksDict copied to clipboard
set_compression_options documentation improvement
Hello,
I'm trying to increase the amount of compression by changing the compression algorithm to zstd. However, it's not clear how to use the set_compression_options function correctly.
The input parameters w_bits, level, strategy, max_dict_bytes are not explained in the documentation so I'm struggling to understand their meaning.
By just setting the compression type to zsts,
opt.set_compression_type(DBCompressionType.zstd())
opt.set_zstd_max_train_bytes(256 * 1024 * 1024)
throws an error,
Exception: Invalid argument: The dictionary size limit (`CompressionOptions::max_dict_bytes`) should be nonzero if we're using zstd's dictionary generator.
that seems to suggest that I should select a value for max_dict_bytes.
Since this library is a wrapper around Rocksdb. I'd refer to rocksdb Wiki for full documentation. However, I do think the current python doc is not good enough.