-
Type:
Task
-
Resolution: Gone away
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Shell
-
None
It seems like the 'no secondary found in replicaset or invalid replica set name' error is thrown when the driver option `connectWithNoPrimary` is set and there is no secondary, even if it's possible to connect directly to the primary (or even when read preference is set to primary).
https://github.com/mongodb-js/mongodb-core/blob/master/lib/topologies/replset.js#L627