Adding stacktrace of the exception I am getting when I use H2 jar 1.3.157 
or above:

*org.h2.jdbc.JdbcSQLException: Connection is broken: 
"java.net.ConnectException:
Connection refused: connect: localhost" [90067-174]
        at 
org.h2.message.DbException.getJdbcSQLException(DbException.java:332)
        at org.h2.message.DbException.get(DbException.java:161)
        at org.h2.engine.SessionRemote.connectServer(SessionRemote.java:417)
        at 
org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.jav
a:305)
        at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:105)
        at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:90)
        at org.h2.Driver.connect(Driver.java:73)
        at java.sql.DriverManager.getConnection(Unknown Source)
        at java.sql.DriverManager.getConnection(Unknown Source)
        at 
com.avaya.induna.server.db.DBConnectionManagerImpl.getConnection(DBCo
nnectionManagerImpl.java:34)
        at 
com.avaya.induna.server.db.backup.BackupImplThread.takeBackup(BackupI
mplThread.java:313)
        at 
com.avaya.induna.server.db.backup.BackupImplThread.run(BackupImplThre
ad.java:175)
Caused by: java.net.ConnectException: Connection refused: connect
        at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
        at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
        at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
        at java.net.PlainSocketImpl.connect(Unknown Source)
        at java.net.SocksSocketImpl.connect(Unknown Source)
        at java.net.Socket.connect(Unknown Source)
        at org.h2.util.NetUtils.createSocket(NetUtils.java:119)
        at org.h2.util.NetUtils.createSocket(NetUtils.java:100)
        at org.h2.engine.SessionRemote.initTransfer(SessionRemote.java:100)
        at org.h2.engine.SessionRemote.connectServer(SessionRemote.java:413)
        ... 9 more
*

On Thursday, October 17, 2013 4:59:58 PM UTC+5:30, aditya wrote:
>
> Hi,
>
> As a part of recent migration to latest H2 jar in my project, I came 
> across a connection issue.
>
> The way it works in our project is that one program starts H2 database in 
> server mode and connects to the database. Another program in the same JVM 
> uses the URL "jdbc:h2:tcp://localhost/myfolder/mydb;IGNORECASE=TRUE" and 
> tries creating a connection using java.sql.DriverManager to same database 
> i.e. *Connection conn = DriverManager.getConnection(this.url, this.user, 
> this.password);
> *
> But the connection object is not getting created after I migrate to latest 
> H2 jar (Earlier we were using 1.2.147 and it was working fine there). After 
> some analysis, I could narrow down on the fact that if I use H2 version 
> 1.3.156 or below, this code works fine but if I start using H2 version 
> 1.3.157 or above, the connection is not created for the second program. I 
> checked the changelog for both these versions (
> http://www.softpedia.com/progChangelog/H2-Database-Engine-Changelog-30870.html)
>  
> but I could not find anything that might throw some light on this. Note 
> that our H2 database does not contain any table with BLOB/CLOB column.
>
> Could you please look into this and let me know what needs to be done to 
> get it working?
>
> Regards,
> Aditya
>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to