Skip to content

Search capabilities are snapshotted at startup and never refresh when an index becomes queryable later #103

Open

Description

@romiluz13

Parent

#90

What to build

The engine detects search capabilities once, at startup, after a bounded wait for search indexes (60 s by default; 180 s with MEMONGO_STRICT_SEARCH_INDEX_READY=1). If an index becomes queryable after that wait, the process keeps reporting the lane as unavailable until it restarts.

CI run 39163428188 (draft PR #102) shows this: every autoEmbed vector index was READY and queryable about 1 s after the API's 60 s wait ended, but the API had already recorded vectorSearch:false.

The API now reports such a lane as a typed capability-absent, so this is visible rather than a silent empty result. Still, a long-running process should not stay degraded after its indexes recover.

Acceptance criteria

  • A lane that is unavailable at startup becomes available without a restart once its serving indexes are queryable, using a bounded re-detection
  • Re-detection never marks a lane available on index readiness alone where a per-document guarantee is claimed (the decision 17 barrier stays the visibility proof)
  • The capability table and /v1/status reflect the refreshed state
  • A test with a fake index lister covers pending → queryable after startup

Blocked by

None. M1 works around this in CI with strict readiness (commit 246294d), which fails startup loudly instead.

🤖 Generated with Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions