Tech
News
Videos
Forums
Jobs
Books
Events
More
Interviews
Live
Learn
Training
Career
Members
Blogs
Challenges
Certification
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
Monitoring Connection Pooling
WhatsApp
Shashi Ray
12y
36.4
k
0
0
25
Blog
To monitor your application's use of connection pooling, you can use the Profiler tool that ships with SQL Server, or the Performance Monitor tool that ships with the Microsoft Windows® 2000 operating system.
To monitor connection pooling with SQL Server Profiler
Click
Start
, point to
Programs
, point to
Microsoft
SQL
Server
, and then click
Profiler
to start Profiler.
On the
File
menu, point to
New
, and then click
Trace
.
Supply connection details, and then click
OK
.
In the
Trace
Properties
dialog box, click the
Events
tab.
In the
Selected event classes
list, ensure that the
Audit
Login
and
Audit
Logout
events are shown beneath
Security
Audit
. To make the trace clearer, remove all other events from the list.
Click
Run
to start the trace. You will see
Audit Login
events when connections are established and
Audit Logout
events when connections are closed.
To monitor connection pooling with Performance Monitor
Click
Start
, point to
Programs
, point to
Administrative
Tools
, and then click
Performance
to start Performance Monitor.
Right-click the graph background, and then click
Add Counters
.
In the
Performance
object
drop-down list, click
SQL Server: General Statistics
.
In the list that appears, click
User Connections
.
Click
Add
,
and then click
Close
.
Managing Security
Although database connection pooling improves the overall scalability of your application, it means you can no longer manage security at the database. This is because to support connection pooling, the connection strings must be identical. If you need to track database operations on a per user basis, consider adding a parameter through which you can pass the user identity and manually log user actions in the database. You need to add this parameter to each operation.
Monitoring Connection Pooling
Up Next
Choosing Pool Sizes
Ebook Download
View all
Printing in C# Made Easy
Read by 22.5k people
Download Now!
Learn
View all
Membership not found