What Gorilla promises and what it gives up

video locked
Enroll to watch

7 mins

Chapters
About
Discussion0
Notes
Be the first to start a conversation!

Gorilla is an in-memory time series database that Facebook uses for monitoring.

It has four requirements:

  1. Fault tolerance. If one of the servers of Gorilla fails, writes continue.
  2. High availability. All writes go to multiple regions, so some data is eventually consistent.
  3. Anomaly detection, for a network outage, a config change or a deployment.
  4. A write heavy load. Writes are 100 times more than reads. In Memcached, reads are a thousand times more than writes.

Memory is expensive, so Facebook stores only the last 26 hours in memory. 85% of all queries fall in that range. Older data stays in the archive, in a cheaper file system.

Small amounts of data may be lost. High availability does not mean durability, and that is not okay for a trading system.

Data points are expensive, so each one is compressed 12 times from its 16 bytes.

Gorilla stores 2 billion unique time series at a 15 second granularity. Read latency is less than 1 millisecond, because other systems read a monitoring system to fix a failure automatically.