1

I am having some connection pool issues in my sharepoint application. Every time that my application tries to fetch some data from an SQL Server 2008 R2, I got this exception:

"Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached."

I know that I am probably having connections leak problems, but I have checked all parts of my code that I am accessing the database, and all of them are implemented with the using() pattern. My SQL Server version is 2008 R2 Express, so I don't have the Profiler Tool to see how many connections my application is actually creating.

I have tried disable the pooling setting the Pooling=false; in my connection string, but I've got the same error. Also, I have tried increase the connection timeout and the max pool size with no success.

Inspecting the User Connections on my SQL Server instance before my application get failed using the perfmon, I have got that the number of connections is not even close to 100 (the default max pool size).

One important information is that if I run this application in another computer here in my office, it works perfectly.

Obs: I am using entity context to access the database and this application is not published, I am just run it locally with vs2013.

If you guys know some good way to inspect the connections behavior of my application or have a idea of what could be happening in my development environment, please share with me.

Thanks.

Rodrigo
  • 53
  • 1
  • 6
  • run exec sp_who. You don't have to have profiler to see connections. – Sean Lange Aug 03 '15 at 21:01
  • sp_who shows all the connections of one specific connection pool or shows all server connections, independently of their connection pools? Is not clear to me which connection level the connections that sp_who and sp_who2 show to us are. – Rodrigo Aug 04 '15 at 17:18
  • I think you are a little confused about connections and connection pooling. Each connection does not have its own pool. The connection pool is the collection of connections. For details sp_who and sp_who2 you should visit the documentation. https://msdn.microsoft.com/en-us/library/ms174313.aspx – Sean Lange Aug 04 '15 at 18:52
  • I agreed. I am confused about how can I inspect the connections pools. I know that only one connection pool is created for several connections with the same arguments and parameters. But I don't know where I can find and see clearly the connections pools parameters. Something like: Connection Pool 'X' : connections= 22, max pool size=100, etc. sp_who show us all the processes in an instance of a server, but I don't understand how can I get information about my specific application's connection pool in there. – Rodrigo Aug 04 '15 at 19:57

0 Answers0