Skip to content

fix: pin atlas local image to latest (MCP-331)#1240

Draft
blva wants to merge 13 commits into
mainfrom
claude/serene-satoshi-1ebed4
Draft

fix: pin atlas local image to latest (MCP-331)#1240
blva wants to merge 13 commits into
mainfrom
claude/serene-satoshi-1ebed4

Conversation

@blva

@blva blva commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Investigates and addresses MCP-331 by pinning into the default Atlas local image: preview.
  • Adjusts tests to cover the expected output from the preview image

Atlas Local v1.0.11 added telemetry startup work (network calls to
gather container and DB details) that pushes container startup time
over testcontainers' default 60s ShellWaitStrategy timeout on Ubuntu
CI. Setting DO_NOT_TRACK=1 skips that work and restores startup times
to ~2.4s (down from ~13.7s).

The image pin to 8.2.2 is kept because MongoDB 8.3+ has a regression
where the search index management task executor enters a brief
"shutting down" state after collection.drop(), causing subsequent
createSearchIndex calls to fail. The TODO comment now explains both
reasons for the pin clearly.
Copilot AI review requested due to automatic review settings June 10, 2026 15:23
@blva
blva requested a review from a team as a code owner June 10, 2026 15:23
@blva
blva requested review from dudaschar and removed request for a team June 10, 2026 15:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the MongoDB Atlas Local search test container setup to reduce startup time regressions introduced by newer Atlas Local images, improving integration test reliability in CI.

Changes:

  • Adds DO_NOT_TRACK=1 to the Atlas Local GenericContainer used for search integration tests to skip telemetry startup work.
  • Expands the inline comment explaining why the Atlas Local image remains pinned to 8.2.x (CI startup timeout + MongoDB 8.3+ search-index regression).

@blva
blva marked this pull request as draft June 10, 2026 16:08
@blva
blva removed the request for review from dudaschar June 10, 2026 16:08
Increases ShellWaitStrategy startup timeout from testcontainers' default 60s
to 120s as a safety net alongside DO_NOT_TRACK=1. The env var keeps actual
startup fast (~2.4s); the higher timeout covers slow CI environments where
container scheduling itself adds overhead.
@blva
blva force-pushed the claude/serene-satoshi-1ebed4 branch from f919b66 to 15986f4 Compare June 10, 2026 17:46
@github-actions

Copy link
Copy Markdown
Contributor

This PR has gone 30 days without any activity and meets the project's definition of "stale". This will be auto-closed if there is no new activity over the next 30 days. If the issue is still relevant and active, you can simply comment with a "bump" to keep it open, or add the label "not_stale". Thanks for keeping our repository healthy!

…-1ebed4

# Conflicts:
#	tests/integration/tools/mongodb/mongodbClusterProcess.ts
@blva blva changed the title fix: add DO_NOT_TRACK=1 to search test container (MCP-331) fix: pin atlas local image to latest (MCP-331) Jul 21, 2026
blva added 3 commits July 21, 2026 20:35
…karound

Testing showed DO_NOT_TRACK + preview pin still fails 4 search-index
schema assertions deterministically, while latest passes cleanly with
no wait strategy and no DO_NOT_TRACK needed. Keeping the wait strategy
against latest was also tested and found to reproducibly destabilize
the container mid-test (connection drops, "interrupted at shutdown"),
so it stays removed.
Vector indexes now include a "quantization" field; classic search
indexes don't return "type" from listSearchIndexes() (only the
collection-indexes tool synthesizes it); and dynamic-mapping search
indexes include "numPartitions". Verified against a real preview
container run (232 passed, 5 skipped, 0 failed, twice).
blva and others added 6 commits July 22, 2026 09:43
Local testing showed this combination (preview image, wait strategy,
no DO_NOT_TRACK) reintroduces connection instability from slow
container startup that DO_NOT_TRACK was added to avoid (12 test
failures locally: MCP client connect failures, MongoNotConnectedError).
Committing per explicit instruction; CI will be the final check.
Root cause traced at the container level: atlas-local's runner does a
bootstrap-then-restart of mongod on every start. mongot reconnects to
the restarted mongod ~1.1s later, but the ShellWaitStrategy's
isWritablePrimary/getSearchIndexes check succeeds right after the
restart, before mongot has reconnected - a race independent of
DO_NOT_TRACK. Removing the wait strategy lets testcontainers fall back
to port-availability plus the test helpers' own connection retry loop,
which absorbs the restart window. Verified twice locally (232 passed,
5 skipped, 0 failed each run) with preview image and no DO_NOT_TRACK.
CI's mitmproxy-intercepted network is consistently slower than local
for the sample-dataset download/import - the same test times out at
600s on main independent of this branch. 270s locally vs 840s+ in CI
before getting killed shows 600s has no headroom there.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants