Try to connect to ReplicaSet first with fallback to single node.