Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
Original topic: 运行中的TiDB集群,修改每层的列簇压缩算法,是否影响数据读写?
Will modifying the compression-per-level
parameter in a running TiDB cluster affect read and write operations? How does the new compression algorithm handle existing SST files in levels L1, L2, L3, etc.? Are they decompressed and then recompressed one by one?
Existing data will only be recompressed during compaction; otherwise, it remains as is. The purpose of compression is to save space, and the upper layers are not that large to begin with, so enabling compression doesn’t have much significance. Additionally, enabling compression affects both read and write performance, especially since data needs to be decompressed during reads.
If the compression algorithm is changed in the following layers, will the stored data be decompressed using the old algorithm and recompressed using the new algorithm in the background?
The new compression algorithm is used for re-compression during compaction.