-
Type: New Feature
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: 2.7.3
-
Component/s: Connectivity
-
Environment:all
when connecting, the c# client uses the System.DnsClient.LookupClient to resolve srv records.
When you have multiple dns servers configured, it only uses the first.
This is the default behavior of the LookupClient.
Correct way to do it would be something like:
var lookupClient = new LookupClient(); foreach (var dnsserver in lookupClient.NameServers) { var response = lookupClient.Query("_mongodb._tcp." + host, QueryType.SRV, QueryClass.IN); if (!response.HasError) break; }
- is related to
-
CSHARP-2968 Exception occurs when using mongodb+srv connection string
- Closed
-
PYTHON-3630 SRV resolution uses only the first nameserver
- Closed