Database / Milvus Vector database Interview questions
What is a Segment in Milvus?
A Segment is the fundamental unit of storage and indexing inside Milvus, sitting below Collections and Partitions in the data hierarchy. As data is inserted, it accumulates into a growing segment held in memory; once that segment reaches a size or time threshold, it's sealed, flushed to persistent object storage, and becomes a candidate for index building.
This two-state design is what lets Milvus support real-time search: newly inserted data is immediately searchable in its growing segment (via a fast temporary index or brute-force scan over the still-small in-memory data) well before the more expensive, fully-optimized index for a sealed segment has finished building. Search results are merged across every relevant segment, growing and sealed alike, so a query sees both fresh and historical data consistently.
Segments are also the unit Milvus distributes across Query Nodes in a cluster; a single large collection's segments can be spread across many nodes, which is central to how Milvus scales horizontally for both storage capacity and search throughput.
More Related questions...