Milvus
Milvus logoMilvus · Feature trail

Force Merge Compaction

1 post · Feb 2022 – Jun 2026

What this trail covers

Milvus introduces Force Merge Compaction, an asynchronous operation that consolidates small, sealed segments into fewer, larger ones. This is particularly beneficial for static, read-heavy collections where a high segment count leads to increased query fan-out overhead. By reducing the number of segments, Force Merge can significantly improve search QPS and reduce latency. The operation is triggered via the `compact()` API with a `target_size` parameter, allowing operators to control the consolidation towards a target size, potentially exceeding the per-segment cap. Experiments show significant QPS gains (76-87%) and latency reduction (p99 down ~33%) on static datasets. It is recommended for quiet windows and when write activity has ceased.

All Milvus trails