Skip to Main Content
  • Questions
  • JDBC vs Oracle NET8 Connection Pooling

Breadcrumb

Question and Answer

Tom Kyte

Thanks for the question, Peter.

Asked: February 19, 2001 - 12:32 am UTC

Last updated: January 14, 2013 - 1:22 pm UTC

Version: 8.1.6

Viewed 1000+ times

You Asked

1. Can you explain the different between JDBC vs Oracle Net8 connection Pooling?

2. In your previous example about web page:
display the first 10 rows which match the query, then the next 10..and so on, giving 2 button (Previous 10 & Next 10)
....

select *
from ( select a.*, rownum r
from ( select *
from t
where x = :host_variable
order by y ) a
where rownum > :LowerBound )
where r < :HigherBound
/


My question:

Each Page will redefine the LowerBound and HigherBound in previous SQL, and hit database when user hit next/previous button?

Thanks for your time,
Peter Cheng


and Tom said...

1) jdbc connection pooling is typically done by having a common username log into the database -- the software then maintains a pool of open connections all under the same user account. when your program needs a connect, one of the common connections is returned to you. when you are done, it is given back to the pool for the next guy. In the database you all appear to be the same user in the same session.

Net8 connection pooling allows many sessions to share the same resources. Each session is separate and distince and will typically have a unique userid associated with it. You do not lose your identity.


2) yes, each page will redefine the lowerbound and hightbound in the SQL.

If you goto:
</code> http://asktom.oracle.com/wa/ask/owa/ask_tom_pkg.search
and view the source, you'll see on that page:

<FORM ACTION="
http://asktom.oracle.com/wa/ask/owa/ask_tom_pkg.search" <code>METHOD="POST">
<INPUT TYPE="hidden" NAME="p_start_row" VALUE="11">
<INPUT TYPE="hidden" NAME="p_search_str" VALUE="">
<INPUT TYPE="submit" VALUE="Next">
</FORM>


Here I am storing the starting row for a NEXT button. If you go and hit the next, the next page will have increased the p_start_row value to 21 and a form for a PREV button will have appeared with the p_start_row = 1.

Rating

  (26 ratings)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Memory Release in case of pooled connections

Shailesh, March 22, 2003 - 2:29 am UTC

1.> In case of JDBC or any other form of connection pooling what happens to memory (PGA) if the oracle server is shutdown and there are, say, 50 number of connections pooled? Is the memory released back to OS?
2.> In case of Net8 connection will exiting through sqlplus will release the memory (PGA) to OS if we issue command shutdown immediate at the server?


Tom Kyte
March 22, 2003 - 9:35 am UTC

1) pga is in the dedicated/shared server processes on the server. if you shutdown -- they "go away", the memory is NOT in the java application.

2) does not make sense to me. if you do a shutdown, the pgas all disappear as the dedicated/shared servers go away.

Re:- Memory release in case of connection pooling

Shailesh, March 24, 2003 - 1:25 am UTC

Thanks for the reply.
When you say "
pga is in the dedicated/shared server processes on the server. if you shutdown -- they "go away", the memory is NOT in the java application." does that imply that if connections are pooled (on different machine than the oracle server) and if there is no client activity(i.e no DML issued) there will be still memory occupied by the pooled connections on oracle server in form of PGA?
Also if we use OS tool (We have HP-Unix) such as GLANCE it shows that there is memory occupied by Oracle process. However if we query V$PROCESS view the column PGA_USED_MEM shows different values.
Do i conclude that as long as connection is live(but not acxtive i.e no DML's) memory associated with it PGA is not released to OS?
Please comment


Tom Kyte
March 24, 2003 - 7:44 am UTC

Yes, if you have a connection pool that maintains a physical connection -- there will be resources on the server (memory and otherwise).

Glance and other tools include the amount of SGA region the process has attached, making them virtually useless here. the SGA is shared memory and you are double counting it. the pga memory reported by Oracle is accurate.

the PGA is owned by the process, correct. it'll stay there.

Re :- Memory Release in case of pooled connections

Shailesh, March 25, 2003 - 2:46 am UTC

Thank You.

JDBC / Net8 connection pooling? Choice?

Tony, May 14, 2003 - 2:17 am UTC

1) When will we have to go for JDBC connection pooling and for Net8 connection pooling? Which one is better? Could you please explain the pros and cons of the two?
2) How to create Net*8 connection pooling?

Thanx a lot.


Tom Kyte
May 14, 2003 - 7:03 am UTC

if you are using an app server, you would typically use the connection pooling there -- they cache the physical connection, which is what you want in ntier.

check out the net admin guide, it has all of the setup.

trinh, May 28, 2003 - 12:32 am UTC

From the JDBC developer guide:
"Connection pooling functionality minimizes
expensive operations in the creation and closing of sessions."
The manual does not explain futher. Could you please elaborate this?
And the concept of the connection pooling is to cache the connection physically. How could I find the number of connections cached at OS (unix) level?

Thanks for answer my query.

Trinh

Tom Kyte
May 28, 2003 - 7:00 am UTC

connection pooling keeps physical connections in a pool, it does not destroy them right away.

hence, the expensive operation of opening network connections, creating processes, etc -- is forgone. you "connect" faster.


you cannot find them as the OS level, they don't exist there. It is a function of your application server. You might be able to use netstat or something to see connections but it would be pretty hard to determine what is what. Just use your application servers utilities/reporting capabilities to see what you got.

Seeing cached connections in appserver under Unix

Piotr Jarmuz, May 28, 2003 - 8:07 am UTC

trinh:

You can use lsof command under Unix to see what sockets the process has opened (lsof stands for list opened files).

I started sqlplus in one console (PID=4425)

and executed in another window:

lsof -p 4425

...
sqlplus 4425 p_jarmuz 6u IPv4 6708519 TCP pitr.asco.de:45609->bill.asco.de:1521 (ESTABLISHED)
...

You can read more about lsof in man section 8.

HTH,
Regards

A reader, May 28, 2003 - 10:18 am UTC

Piotr,
On the SUn Solaris:
$ man lsof
No manual entry for lsof.
$

What's the platform of yours? thanks

trinh

Request for Info

Piotr Jarmuz, May 28, 2003 - 10:48 am UTC

Linux Debian/Intel x86

According to the man pages it should be also supported by Solaris, SunOS, AIX, HP-UX literally all Unix flavors.

As for Solaris itself:
Solaris 2.5.1, 2.6, 7, 8 BETA, and 8 BETA-Refresh

Check your OS version. And maybe on Solaris this command does not come standard and you must install it separately. You want to ask your sysadmin.

Regards

JDBC connection pooling

Sean, May 29, 2003 - 8:04 pm UTC

I have tried to figure out if the jdbc connection pooling configured in our 3-tier web application that includes 9iAS apache, oc4j and the infrastructure DB, and the customer DB as the backend. For some reasons we can not obtain the information of Connection Pooling from the developers.

On the Infra, I found 6 sessions were using " JDBC Thin Client". And on the customer DB, all the sessions were using" JDBC Thin Client". What these tell us? If the JDBC Connection Pooling adopted, only those database connections shown with " JDBC Thin Client" might use the cached connections? The rest of connections were not considered as "cached" connects at all?

select count(*),PROGRAM ,username from v$session where username not in ('SYS') group by PROGRAM ,username order by PROGRAM;

On the 9ias Infrastructure:

COUNT(*) PROGRAM USERNAME
---------- --------------------------------------------- --------------------
5 JDBC Thin Client DCM
1 JDBC Thin Client ORASSO_PS
9 httpd@domain.mil (TNS V1-V3) ORASSO
9 httpd@domain.mil (TNS V1-V3) ORASSO_PUBLIC
93 oidldapd@domain.mil (TNS V1-V3) ODSCOMMON
1 oidmon@domain.mil (TNS V1-V3) ODSCOMMON

On the backend

COUNT(*) PROGRAM USERNAME
---------- --------------------------------------------- ------------
17 JDBC Thin Client product_owner


Tom Kyte
May 30, 2003 - 7:16 am UTC

it tells you nothing. connection pooling can use thick or thin drivers.


you'll have to figure out that "for some reason" part. If the developers quite simply "don't know", well...

Sean, May 30, 2003 - 11:36 am UTC

By the theory, the connection pooling is a frame work for caches of database connections --- "Physically". Some of the connection have been "established", which can be verified from v$session, and others may be the open . These open connections in the pool are no way to be verified at the database level, because they have not been used for the database connections yet. How can I find/verify those have not been used the connections in the pool? Because they should be the "sockets" , can very find out at OS level. I used the following unix command, it gives all the established connections, but I want to find out not-yet connections:
lsof -i TCP:1521.
If you or anyone could help to find out the open connections of jdbc at OS level, I will be very thankful.

As you suggested to use 9iAS monitoring tools to find out the jdbc connection pooling infor, I used the OEM Website, it give very misleading results as such as
One time:
JDBC Usage:
Open JDBC Connections 11,207
Total JDBC Connections 22,387
Active Transactions 0
Transaction Commits 0
Transaction Rollbacks 0

At a other time
JDBC Usage:
Open JDBC Connections 0
Total JDBC Connections 0
Active Transactions 0
Transaction Commits 0
Transaction Rollbacks 0

We know the result were not correct/realistic.



Tom Kyte
May 30, 2003 - 12:01 pm UTC

you can look for processes in v$process that are not associated with sessions. you'll get those when a circuit is setup but no sessions established.

but lots of connection pools are not so subtle, they'll always have a connection and a session.

1521 is probably not the port things are connected on btw, port redirection generally happens.

does jdbc use tnsnames.ora ?

Alvin, June 09, 2003 - 4:05 am UTC

I was configuring the db to be MTS then i was told that JDBC only uses SID only to connect to the db and not tnsnames.ora Is this true ?

If that's the case how do i configure some servers to use dedicated/shared server via overiding thru tnsnames (server=dedicated) or (server=shared) ?

Since the Oracle manual states than one can only be on a shared server settings using net8. And if the what the developer told me was true then configuring the db for MTS would be useless.



Tom Kyte
June 09, 2003 - 7:18 am UTC

that is wrong. jdbc uses net to connect.

look at the URL you give it to connect, what do they look like?

Thin:
("jdbc:oracle:thin:@hostname:port:sid"

has a hostname, port number and sid in it (going to use net for that)

Thick:

("jdbc:oracle:oci8:@tnsnames.entry"

has a tnsnames.ora entry. going to use net for that.



JDBC not using tnsnames...

Alvin, June 09, 2003 - 4:43 am UTC

We're using jdbc thin.

Tom Kyte
June 09, 2003 - 7:21 am UTC

it is the listener that decides "dedicated" or "shared server"

you configure the listener.

Send me a link...

Alvin, June 10, 2003 - 12:00 am UTC

Mr. Kyte can you post a link on how i can configure the listener ? I was reading 8i's Net8 Administrator's Guide
Release 8.1.6 chapter 7 (Configuring the Listener). And i didn't find any topic regarding the configuration of listener.ora for MTS.

I'm remotely administering our Db's and i issued netasst on my prompt and this is what i get and it seems to hang....

/export/home/oracle-> netasst
java.lang.NullPointerException
at oracle.ewt.lwAWT.BufferedFrame._init(Compiled Code)
at oracle.ewt.lwAWT.BufferedFrame.<init>(Compiled Code)
at oracle.sysman.emSDK.client.appContainer.ApplicationFrame.<init>(Compi
led Code)
at oracle.sysman.emSDK.client.appContainer.WebApplication.main(Compiled
Code)


Is it launching a gui ?

Thanks.



Tom Kyte
June 10, 2003 - 8:13 am UTC

otn.oracle.com -> documentation. it is all there, online, just waiting to be read.

In fact, that document has an entire chapter on configuring MTS:

</code> http://docs.oracle.com/docs/cd/A87860_01/doc/network.817/a76933/mts.htm#450520 <code>

(and that is done in the database... the database needs to be MTS savvy)

I've read the chapter before posting...

Alvin, June 10, 2003 - 9:08 pm UTC

That means to configure the DB to MTS init.ora file is where i tinker right ? i thought i might have to add something in the listener.ora file.

Anyways since we're not using port 1521 i DO need to add the local_listener=<value> in the

mts_dispatcher=" (address= ... ) (lis=<lisneter_local_value>) "

right ?

Tom Kyte
June 10, 2003 - 9:19 pm UTC

yes. if you want the database to "register" with the listener.



local_listener init.ora parameter not set...

Kamal Kishore, June 10, 2003 - 9:37 pm UTC

Hi Tom,
It is my understanding that if you want your listener to run on any other port other than 1521, and you need database to be able to register with it, you need to set the local_listener init.ora parameter to point it to port you are using for your listener.

Is it possible to run the listener on any other port other than 1521 and NOT set the local_listener init.ora parameter? Will the connection via listener to the DB still work?

Why I ask this is because, At our client site the PORT setting in tnsnames.ora file uses different port than 1521 and when I checked our client development server, the local_listener init.ora parameter was not set.

But we can still connect to that DB? Is there something else that has been set that eliminates the need to set the local_listener parameter and be still able to connect?
OR maybe I'm missing someting?
Thanks,


Tom Kyte
June 11, 2003 - 6:29 am UTC

either the listener can POINT to a database

or

the database can register with a listener.


you must have your listener configured so as to be aware of that database.

JDBC Connection Pools with unique UN/PW

David Schwartz, June 25, 2003 - 10:15 pm UTC

Is it possible to configure JDBC connection pooling so that users DO NOT loose their unique identity? i.e., each user logs in with their unique user name & password.

Tom Kyte
June 26, 2003 - 8:58 am UTC

Application Server Connection Pool + Proxy Authentication

Robert Boyle, July 16, 2003 - 11:08 am UTC

Tom

We have got the proxy authentication working which is great and solves a huge problem for us, but how do we integrate this into the application server connection pooling? Do we need to write a java class to maintain the pool ourselves, one that also creates the proxy connection? In otherwords, is this a viable method to use with an application server other than 9IAS?

Thanks
Robert

Tom Kyte
July 16, 2003 - 11:30 am UTC

yes it is viable for all you need is the Oracle jdbc drivers and they are usable under any application server.

You can use this with connection pooling as far as I know -- but -- I would encourage you to jump over to devtrends.oracle.com where my "evil java counterpart" Cameron O'Rourke does java stuff like this -- I'm not much of a mid tier programmer myself.

I will go to the dark side!

A reader, July 16, 2003 - 12:04 pm UTC

Thanks Tom!

Regarding Sockets!!!!!!!!!!!

A reader, June 25, 2004 - 5:39 pm UTC

Hi Tom,
We are using java Applications to insert records into our database. The Java Applications use JDBC Oracle OCI Driver.
Earlier we used the thin driver. This has improved the performance by a vast degree. But one problem is still persistent.
The Java Applications use TCP protocol and Connection Pooling. The sessions are closed but the sockets opened on the server side are not released. We were wondering whether there is somthing which can be done in ths database to overcome with this problem. Or what should be do in order to close this sockets on the server side.
Any suggestions are welcome as always.
Thanks as always....... :D



Tom Kyte
June 26, 2004 - 1:11 pm UTC

umm, with connection pooling, the entire goal is to maintain the persistent physical connection. It is expensive to create and establish. It is the entire design goal behind connection pools!



link doesn't work anymore.

A reader, October 26, 2004 - 8:36 pm UTC

The following link is not working anymore.

</code> http://asktom.oracle.com/wa/ask/owa/ask_tom_pkg.search <code>

Could you please fix this?

TNS-04610

dl, March 02, 2005 - 12:15 pm UTC

Tom

We use jdbc through connection pools to a 9ir2 oracle database.

we are getting a very strange error:

TNS-04610: No literals left, reached end of NV pair

This seems to occur sporadically from our live app server to the database during the day. I say sporadically because at this early stage we have not been able to pinpoint when it happens except for:

in a test page which just connects and counts from a table,
when you alter eg the sid in the connect string so that it doesn't resolve to any db on the machine, we consistently get this error, but only through jdbc driver.

I've checked the connection string on the live server but all seems ok and we only occasionally get this error.


I cannot find anything anywhere on metalink or the internet regarding a TNS 04610 error, please do you know what it is??



Tom Kyte
March 02, 2005 - 12:37 pm UTC

please contact support (itar) for this

TNS-04610

Jon, September 05, 2006 - 7:03 pm UTC

I was having similar problems and found that my URL for the java thin client had an incorrect address for the Oracle server that I was trying to hit. That… and I had some classpath problems. I was wondering if you had more information on this error as I’m one that wants to discover exactly why I was getting the error (where it comes from, why it’s a TNS and not an ORA error, etc). I was reading the description for the problem here and now I’m curious as what may be happening with this gentleman’s issue. It’s seems a bit more complicated than just a wrong hostname/ip address as was the case for me. Just curious… don’t expect anything really. But as previously stated... nobody has anything on this error with a casual search.

Oracle Net Connection Pooling

Daks, April 01, 2011 - 8:41 am UTC

Hi,
The above thread was very useful in understanding the Oracle connection pooling.
But I have certain observations and doubts when I implemented the same in our setup. We configured the setup to use MTS and from the v$session table I am able to see that the sessions that are being made are in SHARED mode. My doubts are
1. When I compare the timed statistics from the AWR report of the runs done in DEDICATED mode and SHARED server mode, I dont see any improvement in the connection management time or logons or in the parsing time. Should'nt I find some improvment in these areas when I do the runs in SHARED server mode, because the connections are already existing and the memory used is in the SGA ?
2. One more observation is that, our application creates a lot of short lived processes, these processes connect to the database, do some functionality and then terminate. When I monitor the v$session table, the session id's are distinct for each process, should'nt the new incoming process use the same session which was used by the earlier session (which has just terminated) ?? Is my understanding wrong about this ??
3. What is the relation between the connections present in the DISPATCHER process and the sessions which I see in the v$session table ?

Please make me understand.
Thanks
Tom Kyte
April 12, 2011 - 11:02 am UTC

MTS doesn't exist for many years, the term is 'shared server' these days... Just a technicality.


1) since AWR doesn't (cannot) show you connect time statistics.... How exactly did you observe "no change" in them?

You should find that connecting (measured as the time starting right BEFORE you issue "logon" to the time right AFTER you successfully get logged on) to be smaller, less resource intensive using shared server than dedicated server.

Parsing time - the time to parse a sql statement - should be typically LONGER (more resource intensive) in shared server mode - *everything* will be. Shared server has a far far longer code path to do anything than dedicated server does.

Shared server is to be used when you have hundreds or thousands of concurrent connections and need to throttle back the number of OS processes.

shared server is not FASTER than dedicated server (if you just have one shared server connection and compare it to a single dedicated server connection - dedicated will beat it out everytime)

UNLESS the machine is so slow, so overburdened under dedicated server (managing and servicing hundreds/thousands of processes) that shared server - even though the code path is longer - appears to run faster that is.


2) SIDs are assigned by us and mean nothing to you. We'll reuse them eventually but there is no rule stating "we shall reuse them immediately"


3) nothing necessarily. You can be connected to a dispatcher and have no sessions, or a session, or many sessions. You might not be connected to a dispatcher and have zero, one or many sessions as well.

Oracle Net Connection Pooling

Daks, April 01, 2011 - 9:35 am UTC

Below is the data which I have used for my comparison.
The parameters in the init.ora file are
shared_servers = 20
max_shared_servers = 25
large_pool_size=256M
shared_server_sessions=150
dispatchers = '(ADDRESS =(PROTOCOL=TCP)(LISTENER=LISTENER11)(POOL=on)(CONNECTIONS=300)(SESSIONS=500))'
LOCAL_LISTENER = 'LISTENER11'---- which is listening in the shared server mode.
max_dispatchers = 10

From the AWR reports (time model statistics)

For Dedicated server mode
=========================
Statistic Name Time (s) % of DB Time
DB CPU 432.97 97.21
sql execute elapsed time 359.73 80.77
parse time elapsed 6.66 1.50
failed parse elapsed time 1.70 0.38
hard parse elapsed time 1.64 0.37
connection management call elapsed time 0.62 0.14
sequence load elapsed time 0.07 0.01
PL/SQL execution elapsed time 0.04 0.01
repeated bind elapsed time 0.01 0.00
DB time 445.40
background elapsed time 52.58
background cpu time 6.97

For Shared server mode
=======================
Statistic Name Time (s) % of DB Time
DB CPU 456.51 95.72
sql execute elapsed time 383.06 80.32
parse time elapsed 6.08 1.28
hard parse elapsed time 0.65 0.14
failed parse elapsed time 0.64 0.14
connection management call elapsed time 0.49 0.10
PL/SQL execution elapsed time 0.04 0.01
sequence load elapsed time 0.04 0.01
repeated bind elapsed time 0.01 0.00
DB time 476.91
background elapsed time 57.28
background cpu time 7.22

Thanks
Tom Kyte
April 12, 2011 - 11:31 am UTC

this database isn't doing very much at all - there isn't anything really to compare against.

but you shouldn't expect something like parsing to go faster with shared server. To parse a statement with dedicated server the steps would be:

a) client sends "parse this" request to dedicated server.
b) dedicated server parses it
c) client gets response

with shared server it would be:

a) client sends "parse this" request to dispatcher.
b) dispatcher puts it into a queue in the SGA
c) a free shared server notices the new request and dequeues it
d) the shared server parses it
e) the shared server puts the response from the parse into a queue in the SGA
f) the dispatcher notices it and dequeues it
g) client gets response


oracle processes vs connection pooling

Lynn Sattler, July 14, 2011 - 3:32 pm UTC

Tom,
We had an issue the other day regarding a "JDBC Thin Client" application using oracle v11.1.0.7.

In this asktom post you say:

1) jdbc connection pooling is typically done by having a common username log into the database -- the software then maintains a pool of open connections all under the same user account. when your program needs a connect, one of the common connections is returned to you. when you are done, it is given back to the pool for the next guy. In
the database you all appear to be the same user in the same session.

Net8 connection pooling allows many sessions to share the same resources. Each session is separate and distince and will typically have a unique userid associated with it. You do not lose your identity.
---

The below issue happened on oracle 11.1.0.7 on linux with linux jdbc app servers using oracle dedicated servers.

We had an issue the other day where locks were done by a jdbc application and part of the application and corresponding oracle session hung for hours. An oracle kill 'sid,serial#' did not take effect immediately (got pending I think the wording was). We proceeded to kill the LOCAL=yes linux process, and of course the session then went away.
Afterword I got wondering how safe our kill was considering "connection pooling" is likely involved. I had remembered reading this asktom post that described "connection pooling". I came back to this post and realized I did not have an answer to my concern.

With connection pooling going on, with dedicated server, maybe one linux killing of a LOCAL=NO process could affect many pieces or threads of the jdbc application.

What do you think?

Or is it the case at the moment of the kill, only one jdbc thread (the offending one) can be active and thus affected?

We also have, on another machine, an application running shared server with jdbc connection pooling going on. Killing a shared oracle (ie, D000) process would likely have much more of an affect on killing multiple parts of the application.

Tom, Thanks again for all you do. Your postings are a great resource to the Oracle community.
Tom Kyte
July 18, 2011 - 8:40 am UTC

if you kill a process at the OS level, the application that attempts to use that connect (that attempts to use the CONNECTION object they grabbed from the connection pool associated with that connection to the database) will get an ora-3113 - EOF on communication channel probably. What happens after that is up to the application.


I would not recommend killing at the OS level of any Oracle process. You can use alter system kill session (session will release locks and wait for the client to try to use the connection again - at which time the client will get an ORA-28, your session has been killed) or alter system disconnect session - which will release locks and terminate the session immediately (the client should get an ora-3113)

JDBC Connection Pooling and Oracle Shared Server

A reader, January 10, 2013 - 9:52 pm UTC

This probably doesn't make sense, but just for education purpose--would there be any problems in using both JDBC connection pooling (or application server connection pooling) together with Oracle shared server?
Tom Kyte
January 14, 2013 - 1:22 pm UTC

in some cases - yes.


If you have an application server farm of say 10 application servers and each of the 10 application servers decides they want a connection pool of 300 connections - that gives you 3,000 connections to your database - which is SILLY (I'll be more frank, it is stupid).


Having 3,000 connections is a killer. It doesn't benefit you ever (not until we have 1,500 core machines anyway). It can only kill you (imagine if 500 of those 3,000 tried to become concurrently active on your 12 core machine - you'd be seeing a meltdown). It can only eat resources (think of the memory used by 3,000 connections, think of the OS having to manage 3,000 processes).


Your choices for self preservation would be:

a) use connection manager and have the app servers connect to IT instead of to the database. Have the connection manager multi-plex those three thousand connections down into a much smaller set of connections - maximum of 10xCPU_COUNT, but probably MUCH lower.


b) use shared server to have those three thousand connections multi-plexed into a much smaller pool of shared servers. You'll need a gigantic large pool since your UGA memory will be in the SGA now - but you won't have a gazillion processes sitting out there at least.

c) in the near future you might be able to use DRCP (database resident connection pooling) to do this with JDBC as well.


the best option is

z) get the connection pools to be sized rationally in the first place, nothing - NOTHING - will be better than that solution.

http://www.youtube.com/watch?v=xNDnVOCdvQ0