@@ -31,18 +31,30 @@ override public DbProviderFactory ProviderFactory
31
31
}
32
32
}
33
33
34
- override protected DbConnectionInternal CreateConnection ( DbConnectionOptions options , DbConnectionPoolKey poolKey , object poolGroupProviderInfo , IDbConnectionPool pool , DbConnection owningConnection )
34
+ protected override DbConnectionInternal CreateConnection (
35
+ DbConnectionOptions options ,
36
+ DbConnectionPoolKey poolKey ,
37
+ DbConnectionPoolGroupProviderInfo poolGroupProviderInfo ,
38
+ IDbConnectionPool pool ,
39
+ DbConnection owningConnection )
35
40
{
36
41
return CreateConnection ( options , poolKey , poolGroupProviderInfo , pool , owningConnection , userOptions : null ) ;
37
42
}
38
43
39
- override protected DbConnectionInternal CreateConnection ( DbConnectionOptions options , DbConnectionPoolKey poolKey , object poolGroupProviderInfo , IDbConnectionPool pool , DbConnection owningConnection , DbConnectionOptions userOptions )
44
+ protected override DbConnectionInternal CreateConnection (
45
+ DbConnectionOptions options ,
46
+ DbConnectionPoolKey poolKey ,
47
+ DbConnectionPoolGroupProviderInfo poolGroupProviderInfo ,
48
+ IDbConnectionPool pool ,
49
+ DbConnection owningConnection ,
50
+ DbConnectionOptions userOptions )
40
51
{
41
52
SqlConnectionString opt = ( SqlConnectionString ) options ;
42
53
SqlConnectionPoolKey key = ( SqlConnectionPoolKey ) poolKey ;
43
54
SessionData recoverySessionData = null ;
55
+
44
56
SqlConnection sqlOwningConnection = owningConnection as SqlConnection ;
45
- bool applyTransientFaultHandling = sqlOwningConnection != null ? sqlOwningConnection . _applyTransientFaultHandling : false ;
57
+ bool applyTransientFaultHandling = sqlOwningConnection ? . _applyTransientFaultHandling ?? false ;
46
58
47
59
SqlConnectionString userOpt = null ;
48
60
if ( userOptions != null )
@@ -51,7 +63,7 @@ override protected DbConnectionInternal CreateConnection(DbConnectionOptions opt
51
63
}
52
64
else if ( sqlOwningConnection != null )
53
65
{
54
- userOpt = ( SqlConnectionString ) ( sqlOwningConnection . UserConnectionOptions ) ;
66
+ userOpt = ( SqlConnectionString ) sqlOwningConnection . UserConnectionOptions ;
55
67
}
56
68
57
69
if ( sqlOwningConnection != null )
@@ -138,13 +150,14 @@ override protected DbConnectionInternal CreateConnection(DbConnectionOptions opt
138
150
instanceName ,
139
151
userInstance : false ,
140
152
setEnlistValue : null ) ; // Do not modify the enlist value
153
+ poolGroupProviderInfo = null ;
141
154
}
142
155
143
156
return new SqlInternalConnectionTds (
144
157
identity ,
145
158
opt ,
146
159
key . Credential ,
147
- providerInfo : null ,
160
+ poolGroupProviderInfo ,
148
161
newPassword : string . Empty ,
149
162
newSecurePassword : null ,
150
163
redirectedUserInstance ,
@@ -163,7 +176,7 @@ protected override DbConnectionOptions CreateConnectionOptions(string connection
163
176
return result ;
164
177
}
165
178
166
- override internal DbConnectionPoolProviderInfo CreateConnectionPoolProviderInfo ( DbConnectionOptions connectionOptions )
179
+ internal override DbConnectionPoolProviderInfo CreateConnectionPoolProviderInfo ( DbConnectionOptions connectionOptions )
167
180
{
168
181
DbConnectionPoolProviderInfo providerInfo = null ;
169
182
@@ -233,12 +246,12 @@ override protected DbMetaDataFactory CreateMetaDataFactory(DbConnectionInternal
233
246
internalConnection . ServerVersion ) ; //internalConnection.ServerVersionNormalized);
234
247
}
235
248
236
- override internal DbConnectionPoolGroupProviderInfo CreateConnectionPoolGroupProviderInfo ( DbConnectionOptions connectionOptions )
249
+ internal override DbConnectionPoolGroupProviderInfo CreateConnectionPoolGroupProviderInfo (
250
+ DbConnectionOptions connectionOptions )
237
251
{
238
252
return new SqlConnectionPoolGroupProviderInfo ( ( SqlConnectionString ) connectionOptions ) ;
239
253
}
240
254
241
-
242
255
internal static SqlConnectionString FindSqlConnectionOptions ( SqlConnectionPoolKey key )
243
256
{
244
257
SqlConnectionString connectionOptions = ( SqlConnectionString ) SingletonInstance . FindConnectionOptions ( key ) ;
0 commit comments