Free · Daily brief + weekly playbookDaily 60-sec AI Voice Brief + Weekly Production AI Agent PlaybookGet the brief →
ReleaseInsight · On RadarQdrant Articles→ original

Qdrant Replaces RocksDB with Its Own Gridstore Engine, Doubling Data Ingestion Speed

Qdrant, the vector database, has replaced the general-purpose RocksDB storage with its own Rust engine, Gridstore. RocksDB compacted files in the background, causing latency spikes, yet Qdrant only needs keys that are sequential integers: 0, 1, 2, 3. In a test where one million points were loaded twice, data ingestion became twice as fast and more consistent. The takeaway: if the key shape is known, a narrow engine beats a general-purpose one.

AI-processed from Qdrant Articles; edited by Hamidun News
Qdrant Replaces RocksDB with Its Own Gridstore Engine, Doubling Data Ingestion Speed
Source: Qdrant Articles. Collage: Hamidun News.
Listen to article
Article Fact Sheet & Key Figures
ParameterDetails
Primary sourceQdrant Articles ↗
Editor-in-Chief
Key metric #1Blocks of 128 bytes, an array of pointers, and a bitmask of free space
Key metric #2Finding free space scans about 6 KB of metadata per 1 GB of data
Key metric #3Starting with version 1.15, Gridstore is the default storage for new installations

Qdrant, the vector database used for embedding search, has replaced its internal key-value storage, RocksDB, with its own engine, Gridstore, written in Rust. This kind of storage answers a simple question: given a record number, return its content quickly, for example the metadata (payload) attached to a vector. RocksDB is general-purpose, but Qdrant needs only a small part of its capabilities. In a test in which one million points were loaded into Qdrant twice, data ingestion on Gridstore was twice as fast, and throughput became more stable. For anyone building infrastructure on off-the-shelf general-purpose components, this is a good example of where their ceiling lies.

Why RocksDB Stopped Working for Qdrant

At the start, Qdrant adopted RocksDB: a mature, reliable, well-documented embedded engine. Over time, complaints accumulated. RocksDB's architecture requires compaction, that is, background file consolidation, and this caused random latency spikes. The engine is designed for arbitrary keys, while Qdrant stores only sequential internal IDs: 0, 1, 2, 3, and so on. RocksDB's huge number of settings makes it flexible, but finding the right configuration is hard. On top of that, integrating C++ into a Rust project was a hassle.

The team also looked at ready-made Rust solutions but found nothing suitable. Qdrant needs full control over when and which data is written and flushed to disk. Crash recovery is already in place, and online compaction is not a priority, since that is the job of the optimizers.

How Gridstore Works

The engine consists of three layers.

First, the data layer. Because the keys are sequential numbers, the tracker becomes a plain array of pointers. Each pointer indicates where a value starts and how long it is. To find key 3, you jump to the third position in the array. The values themselves sit in a grid of fixed-size blocks, usually 128 bytes, grouped into page files. A value occupies one or more contiguous blocks, and no block ever holds data from two values.

Second, the mask. This is a bitmap: each bit corresponds to a block, 1 means occupied, 0 means free. On deletion, the value is marked as deleted in the pointer, and its blocks are freed in the mask. On update, the new version is written to a different location, and the old blocks are freed. No costly compaction is needed.

Third, the gaps layer. Scanning the entire mask becomes slow as the storage grows, so the mask is divided into regions. For each region, the engine remembers the largest contiguous free segment, as well as the free space at the beginning and end of the region, so that neighboring regions can be merged when a large value needs the room. According to the authors, with default settings this layer amounts to a few millionths of the storage size: roughly 6 KB of metadata to scan per gigabyte of data. As a result, the remaining operations take almost constant time.

Reliability: Lazy Updates and Rigorous Testing

Three structures must be changed in a coordinated way, and the process can crash at any moment. Qdrant relies on a write-ahead log (WAL): an operation is first recorded there, and after a failure it can be replayed. For this reason, writes must be idempotent: applying them again produces the same state as applying them once.

Gridstore updates metadata lazily. The value itself is written first, while lightweight deferred changes accumulate in a buffer and are applied only on an explicit command. This way, data is not marked as deleted before the new version has been reliably saved. In the worst case, the same write happens twice, which is a small waste of space, but valid data is not overwritten.

The engine was verified in several ways. Model testing compares Gridstore against a plain in-memory hash map: random put, delete, and update operations run on both, and the results are checked after each step. For heavier scenarios, the team built a Crasher rig, which randomly kills and restarts Qdrant under write load, then checks whether any points, vectors, or payloads have been lost. Property-based testing also helps, as it shrinks a failing test down to a minimal example.

Numbers and Limitations

In a microbenchmark based on Bustle, Gridstore showed lower average latency across all three workload types, especially on inserts. In real Qdrant 1.12.6, the test loaded 1 million points twice, and the payload was updated through a separate request without payload indexes. The result: data ingestion was twice as fast and throughput was more stable. One drawback: RocksDB takes slightly less space, but the authors describe the difference as negligible.

The timeline is as follows: in version 1.13, Gridstore became the on-disk storage for payloads and sparse vectors, and starting with 1.15 it is used by default in new deployments. It has not been released as a standalone Rust crate, its API is still changing, and the team only leaves open the possibility of publishing it later.

The practical takeaway for engineers: a general-purpose library is a good choice at the start, but if you know the shape of your keys and already have recovery mechanisms in place, a specialized storage engine can remove latency spikes and simplify tuning. Rigorous tests, such as comparison against a reference model and forced crashes, are essential. The figures, however, come from the authors themselves, and the material contains no independent measurements.

Story

Key Questions Answered

Why RocksDB Stopped Working for Qdrant?

At the start, Qdrant adopted RocksDB: a mature, reliable, well-documented embedded engine. Over time, complaints accumulated. RocksDB's architecture requires compaction, that is, background file consolidation, and this caused random latency spikes. The engine is designed for arbitrary keys, while Qdrant stores only sequential internal IDs: 0, 1, 2, 3, and so on. RocksDB's huge number of settings makes it flexible, but finding the right configuration is hard.

How Gridstore Works?

The engine consists of three layers. First, the data layer. Because the keys are sequential numbers, the tracker becomes a plain array of pointers. Each pointer indicates where a value starts and how long it is. To find key 3, you jump to the third position in the array. The values themselves sit in a grid of fixed-size blocks, usually 128 bytes, grouped into page files. A value occupies one or more contiguous blocks, and no block ever holds data from two values. Second, the mask.

What are the key details on Reliability: Lazy Updates and Rigorous Testing?

Three structures must be changed in a coordinated way, and the process can crash at any moment. Qdrant relies on a write-ahead log (WAL): an operation is first recorded there, and after a failure it can be replayed. For this reason, writes must be idempotent: applying them again produces the same state as applying them once. Gridstore updates metadata lazily. The value itself is written first, while lightweight deferred changes accumulate in a buffer and are applied only on an explicit command.

ZK
Zhemal Khamidun — Head of AI at Alpina Digital · MIPT (academic supervisor of the Tech Entrepreneurship department). Building AI products since 2019. Hamidun News is a pet project that grew into a production aggregator with 6,000+ readers.
✦ Unified AI Workspace · Nomad

Test Frontier LLMs & Autonomous Agents in One Workspace

Run Claude Opus 5.5, GPT-6, Gemini 3.1, and DeepSeek side-by-side in Nomad AI (nomadnet.ai) — unified model routing, deep research, and multimodal workflows under one subscription.

Try Nomad AI →Launch Nomad Agent
Jemal Hamidun

Editor-in-chief · Cite this analysis

Jemal Hamidun

Head of AI at Alpina Digital · Academic Supervisor of the Tech Entrepreneurship Department at MIPT

Head of AI & CPO of AlpinaGPT at Alpina Digital, Academic Lead of Tech Entrepreneurship at MIPT. Founder of Hamidun News and Vibe Academy.

Ready-to-paste citation for journalists, blogs and Telegram channels

Source: Hamidun News — Qdrant Replaces RocksDB with Its Own Gridstore Engine, Doubling Data Ingestion Speed https://news.hamidun.com/en/news/16846/qdrant-replaces-rocksdb-with-its-own-gridstore-engine-doubli

What do you think?
Loading comments…