You upsert a document and query for it 200 milliseconds later, but it never appears. Pick the most likely cause.
Options
The write landed in a buffer or fresh segment that is not yet searchable; the index has a freshness lag between acknowledged write and queryable vector
The vector was silently rejected because its values were not normalized to unit length
ANN search is approximate, so a brand new vector has a permanently lower chance of being found
The query embedding model must be restarted before it can see new vectors
Freshness lag is the right answer because every production vector database documents some version of this behaviour.
The write path looks like: client sends upsert, engine writes to a write ahead log for durability, engine adds the vector to an in memory buffer or a fresh segment, engine acknowledges success to the client. None of those steps update the searchable index. A background task flushes the buffer or merges the segment on its own schedule, and the vector becomes queryable only after that.
The window is engine specific:
- Pinecone serverless. A few seconds at the freshness layer, longer to fully merge into the main index.
- Elasticsearch / OpenSearch. Default refresh interval is 1 second; can be lowered at a CPU cost or set to immediate per request.
- Milvus. Explicit consistency levels (strong, bounded, session, eventual); eventual is the cheap default.
- Qdrant. Writes are visible after the WAL flush, typically sub-second but configurable.
- pgvector. Writes are immediately visible in the table but only show up in the IVFFlat or HNSW index after the index sees them, depending on engine version and settings.
The trap for application developers is assuming write after read consistency. Vector databases default to eventual consistency on the read path for performance reasons. The fix is to either query the strong consistency path (where supported), to wait a documented refresh interval, or to design the application so freshness lag is acceptable (a chat that displays the just written doc from the application database, not the index).