Almost, but not exactly. ;-)

The connection does not remain with the thread for the life of the
thread, but rather the thread gets the connection from the pool (the
pool marks it as used so no one else gets it), then uses it, then
closes it (which just tells the pool that it can give it to others).

I have not ever looked into if it checks for active transactions, I'd
guess that the assumption is that they are clean.

Larry


On 2/7/07, Abdullah Kauchali <[EMAIL PROTECTED]> wrote:
From:       Larry Meadors [EMAIL PROTECTED]:
>All connectins and transactions are managed using thread local
>storage, so each thread has it's own connection, etc..

(Thanks Larry!)

Ok.  Understood.  So, each time a new thread that uses SqlMapClientImpl is 
spawned, a Connection object is removed from the pool and remains with the 
thread local instance of SqlMapClientImpl until the thread is finished (or just 
before it), at which point the Connection object is returned to the pool?

Is there any checking of active transactions on Connection objects before 
getting it from and after putting it back into the pool?

Kind regards,

A





Reply via email to