简体   繁体   中英

Connection pool setting of SQL Server connection string

I maintain a legacy ASP.Net Web application (using .Net 2.0 + SQL Server 2005 Enterprise + VSTS 2008 + C# + ADO.Net). Here is the connection string the legacy application is using (the legacy application is using SQL Server authentication mode):

"server=***;database=***;uid=***;pwd=***;pooling=false;max pool size=100"

I think the connection string is wrong because:

  1. Since the setting of pooling is false, but it also set pool size -- conflicting.
  2. Even if there are conflicting settings, I think pooling = false takes effect, Ie connection pool is not used by the ADO.Net application.

Is my understanding correct?

Yes. You are right. if pooling = false, the max pool size will not take effect. but the connection is not necessarily wrong. it is still valid.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM