db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marcelo Iury Oliveira / Projeto Ourgrid <i...@lsd.ufcg.edu.br>
Subject Connections does not close
Date Sat, 20 May 2006 21:03:31 GMT
Hello all!

I am developing a P2P application using Apache Derby to cache a users 
information. 

My application performs a sequence of many database connections to the 
localhost Network Server.
It closes all resources (resultset, statemant and connection) used int 
the query process. However connections still persists at OS level.
When the jdbc api allocates an port used by any of these opened 
connections, exception is launched.

I try to use connection pool, but happens the same  error.

Am I forgot any step to close these connections? Is there a abrupt 
approach to close connections?

Cheers,
Marcelo Iury


PS:
aused by: org.apache.derby.client.am.DisconnectException: 
java.security.PrivilegedActionException : Error opening socket to server 
localhost on port 1527 with message : null
        at org.apache.derby.client.net.NetAgent.<init>(Unknown Source)
        at org.apache.derby.client.net.NetConnection.newAgent_(Unknown 
Source)
        at org.apache.derby.client.am.Connection.<init>(Unknown Source)
        at org.apache.derby.client.net.NetConnection.<init>(Unknown Source)
        at org.apache.derby.jdbc.ClientDriver.connect(Unknown Source)
        at java.sql.DriverManager.getConnection(Unknown Source)



PSS: netstat -panute | grep 1527

tcp6       0      0 ::ffff:127.0.0.1:35383  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35368  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35369  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35370  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35371  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35372  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35373  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35374  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35375  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35360  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35361  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35362  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35363  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35364  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35365  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35366  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35367  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35352  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35353  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35354  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35355  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35356  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35357  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35358  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35359  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35344  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35345  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -
tcp6       0      0 ::ffff:127.0.0.1:35346  ::ffff:127.0.0.1:1527   
TIME_WAIT  0          0          -

........ There are more opened connections : (






Mime
View raw message