Back to roadmap
Module 7 · NoSQL, Search, Graph, ObjectDay 06220 min

Time-Series Databases

Built for append-only timestamped data.

Day 062

Time-Series Databases

Source
client
Ingest
service
TSDB
datastore
Rollups
datastore
Signal path
Time-series ingestion → storage → rollups
Source
client
flow
Ingest
service
Ingest
service
flow
TSDB
datastore
TSDB
datastore
flow
Rollups
datastore
Memory hook

Time-Series Databases: built for append-only timestamped data

Mental model

match the datastore to the access pattern

Design lens

TSDBs are great for adds, weak for ad-hoc joins.

Recall anchors
IngestStorageRollups

Why it matters

Time-series DBs store streams of timestamped points (metrics, sensor data). They optimize for append-only writes, range scans, and rollups via downsampling and retention.

Deep dive

Compression is huge: delta-of-delta + bit-packing on timestamps; gorilla-style float compression.

Retention: keep raw 7d, 1m rollups 30d, 1h rollups 1y.

Prometheus: pull-based, label-rich; InfluxDB and Timescale are push-based and richer for analytical queries.

Demo / scenario

App metrics with 1M points/sec.

  1. Push to TSDB, label by service/host/region.
  2. Downsample to 1m and 1h continuously.
  3. Drop raw after 7d; keep rollups longer.
  4. Cheap dashboards over rollups.

Tradeoffs

  • TSDBs are great for adds, weak for ad-hoc joins.
  • High-cardinality labels can blow up indexes.
  • Plan retention or storage costs explode.

Diagram

Source
Ingest
TSDB
Rollups
Time-series ingestion → storage → rollups.

Mind map

Check yourself

Loading quiz…

Sources & further reading