|
From: Kenneth P. <tr...@ho...> - 2005-06-21 07:40:09
|
Hi If I loose the connection to my database for a short time (1-2minutes), MSH do not operate properly afterwards. When the connection is lost this occurs in the MSH_client.log: 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => DbConnectionPool.getConnection 2005-06-21 09:13:34,384 DEBUG [Thread-8]: <= DbConnectionPool.getConnection 2005-06-21 09:13:34,384 ERROR [Thread-8]: [10002] Unknown error Exception: java.sql.SQLException Message: I/O Error: Connection reset by peer: socket write error 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => Transaction.rollback (txID: #2321) 2005-06-21 09:13:34,384 ERROR [Thread-8]: [10315] Cannot rollback DB changes Exception: java.sql.SQLException Message: Invalid state, the Connection object is closed. 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => DbConnectionPool.freeConnection 2005-06-21 09:13:34,384 DEBUG [Thread-8]: <= DbConnectionPool.freeConnection 2005-06-21 09:13:34,384 DEBUG [Thread-8]: <= Transaction.rollback 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => MessageServiceHandler.getNextUndeliveredMessage 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => MessageServer.getUndeliveredMessages 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => DbConnectionPool.getConnection 2005-06-21 09:13:34,384 DEBUG [Thread-8]: => DbConnectionPool.createConnection 2005-06-21 09:13:35,352 ERROR [Thread-8]: [10306] Cannot create DB connection Exception: java.sql.SQLException Message: Network error IOException: Connection refused: connect 2005-06-21 09:13:35,352 DEBUG [Thread-8]: => Transaction.rollback (txID: #2323) 2005-06-21 09:13:35,352 DEBUG [Thread-8]: <= Transaction.rollback 2005-06-21 09:13:35,352 DEBUG [Thread-8]: => MessageServiceHandler.getNextUndeliveredMessage 2005-06-21 09:13:35,352 DEBUG [Thread-8]: => MessageServer.getUndeliveredMessages 2005-06-21 09:13:35,352 DEBUG [Thread-8]: => DbConnectionPool.getConnection 2005-06-21 09:13:35,352 DEBUG [Thread-8]: => DbConnectionPool.createConnection After the connection is restored MSH do not seem to get a proper connection. This occurs then in the MSH_Client.log: 2005-06-21 09:13:42,384 ERROR [Thread-8]: [10306] Cannot create DB connection Exception: java.sql.SQLException Message: Network error IOException: Connection refused: connect 2005-06-21 09:13:42,384 DEBUG [Thread-8]: => Transaction.rollback (txID: #2338) 2005-06-21 09:13:42,384 DEBUG [Thread-8]: <= Transaction.rollback 2005-06-21 09:13:42,384 DEBUG [Thread-8]: => MessageServiceHandler.getNextUndeliveredMessage 2005-06-21 09:13:42,384 DEBUG [Thread-8]: => MessageServer.getUndeliveredMessages 2005-06-21 09:13:42,384 DEBUG [Thread-8]: => DbConnectionPool.getConnection 2005-06-21 09:13:42,384 DEBUG [Thread-8]: => DbConnectionPool.createConnection 2005-06-21 09:13:43,384 ERROR [Thread-8]: [10306] Cannot create DB connection Exception: java.sql.SQLException Message: Network error IOException: Connection refused: connect When i try to send a message through MSH i get this: hk.hku.cecid.phoenix.message.handler.RequestException: Failed to send query to MSH. HTTP response code = 200 HTTP response message = OK at hk.hku.cecid.phoenix.message.handler.Request.expectMapResponse(Unknown Source) at hk.hku.cecid.phoenix.message.handler.Request.sendMessageServiceHandlerConfig(Unknown Source) at hk.hku.cecid.phoenix.message.handler.Request.register(Unknown Source) at hk.hku.cecid.phoenix.message.handler.Request.<init>(Unknown Source) at hk.hku.cecid.phoenix.message.handler.Request.<init>(Unknown Source) at com.mysupply.ebxi.msh.MessageManager.sendMessage(MessageManager.java:149) And of course I can not receive any messages through MSH either. Does anybody have the same problems, after a lost database connection? The other part of my application that uses MSH, is right back in action when the database connection is restored, but not MSH. The app is running on jboss-4.0.1 (Tomcat 5.0.28), Java jdk1.5.0_01. The database is Microsofts MSSQL 2000. The driver for MSSQL is JTDS 1.0. I have added this: <check-valid-connection-sql>select * from some_table</check-valid-connection-sql> to my datasource file: mssql-ds.xml which is deployed along with msh.war. Everything is working fine, for days, until I loose the database connection for a few minutes. _________________________________________________________________ Del din verden med MSN Spaces http://spaces.msn.com |