Connection Pool

J

Jim Heavey

How do I set up a Connection Pool?

How can I look on the server and see how many connections are being used by
my application? I am pretty sure that my application must be leaving
connections open, because I begin to receive error message indicating that
the system can not open a connection and I should check my connection pool,
with me being the only one on the server, this should not really be a
problem. I am not sure why I do not receive the same error message while
testing on my own machine, but I am guessing that somehow or another those
connections must be being closed by the system some how.

Your assistance would be greatly appreciated!!!!
 
R

Rick Strahl [MVP]

Hi Jim,

You can use performance counters to see the SQL connection pool, which is
probably the easiest way to see this. You'll want to look at open
connections as well as the .Net sql counters for this (can't recall offhand
what the names are - use Server Explorer or PerfMon to check them out).

+++ Rick ---

--

Rick Strahl
West Wind Technologies
http://www.west-wind.com/
http://www.west-wind.com/weblog/
 
A

Ashish M Bhonkiya

Hi,

To add to Rick

Performance Counters for Connection Pooling
The .NET Framework Data Provider for SQL Server adds several performance
counters that enable you to fine-tune connection pooling characteristics,
detect intermittent problems related to failed connection attempts, and
detect problems related to timed-out requests to your SQL Server.

The following table lists the connection pooling counters that can be
accessed in Performance Monitor under the ".NET CLR Data" performance
object.

Counter
Description
SqlClient: Current # of pooled and non pooled connections
Current number of connections, pooled or not.
SqlClient: Current # pooled connections
Current number of connections in all pools associated with the process.
SqlClient: Current # connection pools
Current number of pools associated with the process.
SqlClient: Peak # pooled connections
The highest number of connections in all pools since the process started.

Note: this counter is only available when associated with a specific process
instance.

The _Global instance will always return 0.
SqlClient: Total # failed connects The total number of connection open
attempts that have failed for any reason.

Source::
http://msdn.microsoft.com/library/d...nectionpoolingforsqlservernetdataprovider.asp

Regards
Ashish M Bhonkiya
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,150
Latest member
MakersCBDReviews
Top