views:

496

answers:

3

What is the best way to handle connection pooling with Oracle 11g and asp.net, I'm having issues where Oracle refuses to open up any new connections for the web app after a while.

This causes the request to time out and queue up.!

EDIT: Is there anything that I need to do in Oracle to fine tune this?

A: 

Closing the connections is all you need to do. The framework should handle all of the pooling.

Rob A
I already do that, I close ALL connections.
hminaya
You could try the odp.net performance counters.
Rob A
A: 

Querying the v$session would show all outstanding sessions. How many connections do you have and how quickly are you trying to create/disconnect them ? Shared servers is one mechanism to have multiple end clients share a limited number of connections.

Gary
I see hundreds of sessions there. But where do I define/control it?
hminaya
A: 

Since you didn't mention your Oracle config, its hard to tell you a first course of action, so you need to clarify how many sessions you have.

select username, count(1) from v$session group by username;

Oracle's max is controlled by the "PROCESSES" instance parameter. The default may be something like 150. You may try bumping that to 300 or so for an OLTP web app, however, if you do have a leak, it will only delay the inevitable. But check the PROCESSES is at least as large as your "Max Pool Size" setting for your Oracle ADO connection string. Default for 11g ODP.NET is 100 I think.

mrjoltcola