Title: SV: Leaked Connections .. URGENT !!!
See i believe that the root cause of the problem is that u are trying to close the connection in the try block.... do the same in the finally block and evrything will be jus fine.......
 
u must be having something like
try
{
    Connection con = ....
    con.....
    con.close();
}catch(Exception e)
{
}
Instead do something like
try
{
    Connection con = ....
    con.....
 }catch(Exception e)
{
}
 finally
{
   con.close();
}
  
----- Original Message -----
Sent: Friday, August 10, 2001 4:22 PM
Subject: SV: Leaked Connections .. URGENT !!!

The bean you are talking about, that wouldn't happend to be en EnterpriseBean would it? If it is, and you're holding on to a connection After orion has committed a transaction to it, then you're out of luck with that solution. Why would you want to laziliy load something like that on a serverside system? You need to use the connection and when you're done, return it, and all that has to be done withting the current UserTransaction context.

regards,
Patrik Andersson

-----Ursprungligt meddelande-----
Från: Engst Oliver (Platinion) [mailto:[EMAIL PROTECTED]]
Skickat: den 10 augusti 2001 12:27
Till: Orion-Interest
Ämne: Leaked Connections .. URGENT !!!


If somebody could help me I would be very pleased.

I have a Bean, which is getting a Connection, fetching some data and then
creates a background Thread which fetches the rest of the data. This
additional background thread closes the connection in a Try{} finally block.
All works fine. I have System.out.println(... ) to check it. All connection
which are opened will are closed earlier or later. Depending of the fetching
time.


ORION is throwing its Exception that the connection is leaked:

OrionCMTConnection not closed, check your code!
LogicalDriverManagerXAConnection not closed, check your code!
(Use -Djdbc.connection.debug=true to find out where the leaked connection
was created)

That would be ok. But after 6 or 7 times it doesnt give me a new Connection.
The Exception is:

java.sql.SQLException: Unable to allocate a connection
        at
com.evermind.sql.OrionPooledDataSource.getConnectionOrionPooledDataSource.ja
va:194)

How can I avoid this ? It's extremely urgent because I have to deliver at
next Friday.

Thanks in Advance
Oliver


*********************************************************
Disclaimer

This message (including any attachments) contains
confidential information intended for a specific
individual and purpose, and is protected by law.
If you are not the intended recipient, you should
delete this message and are hereby notified that
any disclosure, copying, or distribution of this
message, or the taking of any action based on it,
is strictly prohibited.

*********************************************************
Visit us at http://www.mahindrabt.com

Reply via email to