Skip to content

Commit

Permalink
Add SqlConnection Async to TDS
Browse files Browse the repository at this point in the history
Add the setting of the Asynchronous Variable assignment to SqlInternalConnectionTds
  • Loading branch information
H-Yeo committed Dec 8, 2023
1 parent db3e726 commit 71054c0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1911,7 +1911,8 @@ private void AttemptOneLogin(
ignoreSniOpenTimeout,
timeout.LegacyTimerExpire,
ConnectionOptions,
withFailover);
withFailover,
Connection.IsAsyncPipeOption);

_timeoutErrorInternal.EndPhase(SqlConnectionTimeoutErrorPhase.ConsumePreLoginHandshake);
_timeoutErrorInternal.SetAndBeginPhase(SqlConnectionTimeoutErrorPhase.LoginBegin);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,8 @@ internal void Connect(
bool ignoreSniOpenTimeout,
long timerExpire,
SqlConnectionString connectionOptions,
bool withFailover)
bool withFailover,
bool isAsyncPipeOption)
{
SqlConnectionEncryptOption encrypt = connectionOptions.Encrypt;
bool isTlsFirst = (encrypt == SqlConnectionEncryptOption.Strict);
Expand Down Expand Up @@ -451,7 +452,7 @@ internal void Connect(
out instanceName,
ref _sniSpnBuffer,
false,
async: true,
async: isAsyncPipeOption,
fParallel,
_connHandler.ConnectionOptions.IPAddressPreference,
FQDNforDNSCache,
Expand Down Expand Up @@ -550,7 +551,7 @@ internal void Connect(
out instanceName,
ref _sniSpnBuffer,
true,
async: true,
async: isAsyncPipeOption,
fParallel,
_connHandler.ConnectionOptions.IPAddressPreference,
FQDNforDNSCache,
Expand Down

0 comments on commit 71054c0

Please sign in to comment.