Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
divya.pdsj
Starting Member
3 Posts |
Posted - 2011-07-20 : 08:18:13
|
| Hello everyone,Issue Description:The Application connects to a SQL server on the back-end. This SQL database is in a Clustered environment. When the SQL database is patched, the database automatically fails over from Node A to Node B. Applications which connect to the cluster should not experience any outage. But whenever the patching is done, the connection to the SQL Server is lost and we get the following exception in the logs:2011-06-19 04:05:54,983 ERROR WebContainer : 50 dataaccess.ProductDAOImpl com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred while applying a parameter map. --- Check the ProductFeature.getProductIDs-InlineParameterMap. --- Check the statement (query failed). --- Cause: java.lang.ClassCastException: java.net.SocketException incompatible with java.sql.SQLException If the application is restarted, it starts working again.Please help me out.Thanks. |
|
|
russell
Pyro-ma-ni-yak
5072 Posts |
Posted - 2011-07-20 : 12:09:37
|
| Connections are lost when a node fails over. The application should retry on failed connection. |
 |
|
|
divya.pdsj
Starting Member
3 Posts |
Posted - 2011-07-21 : 07:11:46
|
| Thanks Russell for the reply.But we don't handle the connection from the code. Connections are done through the WAS Configuration Set up.In this case how can we handle this scenario. Please help |
 |
|
|
russell
Pyro-ma-ni-yak
5072 Posts |
Posted - 2011-07-21 : 11:13:07
|
| At the point in the Java app where it fails, there needs to be an error handler that will let it retry. |
 |
|
|
divya.pdsj
Starting Member
3 Posts |
Posted - 2011-07-25 : 23:34:30
|
| Thanks again for your reply.I have an other question:Is there any possibility to auto-refresh the datasource connection in the WAS Configuration, once the connection is lost/disconnected?Beacause catching the exception thrown and retrying for the connection at that point is not as per our design(Not sure if this would work if implemented also). As mentioned earlier datasource connections are not handled by the code they are handled by the WAS Configuration.Thanks in advance. |
 |
|
|
|
|
|