Home / Companies / Tiger Data / Blog / Post Details
Content Deep Dive

Time-series compression algorithms, explained

Blog post from Tiger Data

Post Details
Company
Date Published
Author
Joshua Lockerman
Word Count
3,222
Language
English
Hacker News Points
190
Summary

Compression algorithms, such as delta-delta encoding, Simple-8b, and XOR-based methods, play a crucial role in efficiently managing time-series data by significantly reducing storage costs and enhancing query speeds. These algorithms allow data to be encoded using fewer bits than its original representation, with techniques like delta-encoding and delta-of-delta encoding focusing on storing only the differences between data points, particularly effective for time-series data that changes gradually. Simple-8b further optimizes storage by encoding variable-length integers in fixed-size blocks, while run-length encoding compresses repeated values efficiently. XOR-based compression, as used in the Gorilla database, provides effective compression for floating-point numbers by storing only differing bits between successive values. TimescaleDB, an open-source time-series database, implements these algorithms to achieve over 90% storage efficiency, employing different compression techniques based on data type and enabling faster queries through reverse data decompression. The strategic use of these algorithms not only leads to substantial cost savings but also enhances compute performance by reducing the data footprint in storage systems.