[COMPASS-4539] Fix direct connecting to a secondary with readPreference=secondary Created: 15/Dec/20  Updated: 29/Oct/23  Resolved: 17/Dec/20

Status: Closed
Project: Compass
Component/s: Connectivity
Affects Version/s: None
Fix Version/s: 1.24.6

Type: Bug Priority: Major - P3
Reporter: Rhys Howell Assignee: Rhys Howell
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screen Shot 2020-12-15 at 10.11.55 AM.png    
Issue Links:
Related
is related to COMPASS-6595 Initial ping command does not inherit... Closed
Documentation Changes: Not Needed
Sprint: Iteration Star Apple

 Description   

Repro:
Using replica set from https://github.com/mongodb-js/devtools-docker-test-envs#replicaset

  • Note: do not add the replica set hosts to /etc/hosts so they do not resolve.
    In Compass then connect with connection string:

    mongodb://root:password123@localhost:28003/?authSource=admin&readPreference=secondary&appname=MongoDB%20Compass%20Isolated%20Edition&ssl=falseĀ 



 Comments   
Comment by Githook User [ 22/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#286)
Branch: expose-connection-options
https://github.com/mongodb-js/data-service/commit/889fa774fc0df7bf47799ab1203f719d899231d0

Comment by Githook User [ 22/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#282)" (#283)

This reverts commit f2bd36d67f169e2fbbed963a1bbec7583e0bd89e.
Branch: expose-connection-options
https://github.com/mongodb-js/data-service/commit/bd8c323ab8147993bcd8eec0d4f60a783c120863

Comment by Githook User [ 22/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#282)
Branch: expose-connection-options
https://github.com/mongodb-js/data-service/commit/f2bd36d67f169e2fbbed963a1bbec7583e0bd89e

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix(connectivity): use older driver defaults for directConnection and readPreference COMPASS-4539 COMPASS-4534 (#2083)
Branch: 1.24-releases
https://github.com/mongodb-js/compass/commit/6f49eac32021f83d66377a0a22e4b927a0a0fb96

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix(connection-model): directConnection and readPreference connectivity fix COMPASS-4539 COMPASS-4534 (#2078)" (#2082)

This reverts commit b10a3dfd11f4d0e873db11db915ffa6950a75ab0.
Branch: 1.24-releases
https://github.com/mongodb-js/compass/commit/bc494df4301eea1c75248578c3fb2113a6a3e6dc

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix(connectivity): use older driver defaults for directConnection and readPreference COMPASS-4539 COMPASS-4534 (#2083)
Branch: master
https://github.com/mongodb-js/compass/commit/6f49eac32021f83d66377a0a22e4b927a0a0fb96

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#286)
Branch: master
https://github.com/mongodb-js/data-service/commit/889fa774fc0df7bf47799ab1203f719d899231d0

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#282)" (#283)

This reverts commit f2bd36d67f169e2fbbed963a1bbec7583e0bd89e.
Branch: master
https://github.com/mongodb-js/data-service/commit/bd8c323ab8147993bcd8eec0d4f60a783c120863

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#282)"

This reverts commit f2bd36d67f169e2fbbed963a1bbec7583e0bd89e.
Branch: revert-282-COMPASS-4539/pass-read-preference-with-db-command
https://github.com/mongodb-js/data-service/commit/35106a3b93dedf909a539d360d17e76926f8de11

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix(connection-model): directConnection and readPreference connectivity fix COMPASS-4539 COMPASS-4534 (#2078)" (#2082)

This reverts commit b10a3dfd11f4d0e873db11db915ffa6950a75ab0.
Branch: master
https://github.com/mongodb-js/compass/commit/bc494df4301eea1c75248578c3fb2113a6a3e6dc

Comment by Githook User [ 16/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: Revert "fix(connection-model): directConnection and readPreference connectivity fix COMPASS-4539 COMPASS-4534 (#2078)"

This reverts commit b10a3dfd11f4d0e873db11db915ffa6950a75ab0.
Branch: revert-2078-bump-connection-model-and-dataservice-for-direct-connection-fix
https://github.com/mongodb-js/compass/commit/587718abb77d6082758dcfac8ad94aa46cfb041b

Comment by Githook User [ 15/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix(connection-model): directConnection and readPreference connectivity fix COMPASS-4539 COMPASS-4534 (#2078)
Branch: 1.24-releases
https://github.com/mongodb-js/compass/commit/b10a3dfd11f4d0e873db11db915ffa6950a75ab0

Comment by Githook User [ 15/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix(connection-model): directConnection and readPreference connectivity fix COMPASS-4539 COMPASS-4534 (#2078)
Branch: master
https://github.com/mongodb-js/compass/commit/b10a3dfd11f4d0e873db11db915ffa6950a75ab0

Comment by Githook User [ 15/Dec/20 ]

Author:

{'name': 'Rhys', 'email': 'Anemy@users.noreply.github.com', 'username': 'Anemy'}

Message: fix: Explicitly pass read preference with db.command commands COMPASS-4539 (#282)
Branch: master
https://github.com/mongodb-js/data-service/commit/f2bd36d67f169e2fbbed963a1bbec7583e0bd89e

Generated at Wed Feb 07 22:36:43 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.