You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SNI/SNITcpHandle.cs
+17-6
Original file line number
Diff line number
Diff line change
@@ -146,9 +146,9 @@ public SNITCPHandle(string serverName, int port, long timerExpire, bool parallel
146
146
boolreportError=true;
147
147
148
148
SqlClientEventSource.Log.TrySNITraceEvent(nameof(SNITCPHandle),EventType.INFO,"Connection Id {0}, Connecting to serverName {1} and port {2}",args0:_connectionId,args1:serverName,args2:port);
149
-
// We will always first try to connect with serverName as before and let the DNS server to resolve the serverName.
150
-
// If the DSN resolution fails, we will try with IPs in the DNS cache if existed. We try with cached IPs based on IPAddressPreference.
151
-
// The exceptions will be throw to upper level and be handled as before.
149
+
// We will always first try to connect with serverName as before and let DNS resolve the serverName.
150
+
// If DNS resolution fails, we will try with IPs in the DNS cache if they exist. We try with cached IPs based on IPAddressPreference.
151
+
// Exceptions will be thrown to the caller and be handled as before.
152
152
try
153
153
{
154
154
if(parallel)
@@ -280,7 +280,12 @@ private Socket TryConnectParallel(string hostName, int port, TimeSpan ts, bool i
0 commit comments