Skip to content

Conversation

@FGasper
Copy link
Collaborator

@FGasper FGasper commented Oct 21, 2025

mongosh defaults single-node connections to a direct connection. This changeset applies that logic to migration-verifier so that, if a connection string includes only a single node, the verifier will always connect to it.

This is useful, e.g., when using a single, containerized mongod for the metadata DB and the mongod’s replication is set up to reference its hostname. In that case a direct connection is necessary when using Podman or other container engines that don’t “inject” the container name into the host’s name resolution (as, e.g., Docker Desktop on macOS does).

At the same time, this changeset avoids the above problem by explicitly making the documentation’s container one-liner bind to localhost.

@FGasper FGasper changed the title Default single-node connection strings to a direct connection. Default single-node connstrs to direct connection; improve docs Oct 21, 2025
@FGasper FGasper requested a review from tdq45gj October 21, 2025 14:43
Copy link
Collaborator

@tdq45gj tdq45gj left a comment

Choose a reason for hiding this comment

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

LGTM

@FGasper FGasper merged commit 94563b7 into mongodb-labs:main Oct 21, 2025
99 checks passed
@FGasper FGasper deleted the felipe_default_direct_connection branch October 21, 2025 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants