We have an application which connects to the sql server database ( Always on cluster ) through a JDBC connection and this gets the following errors at times .. There are no corresponding errors or alerts seen at the sql server error logs..
How do we approach this problem ? Any pointers will be appreciated ..
The connection is closed.
com.microsoft.sqlserver.jdbc.SQLServerException: The connection is closed.
Answer by Magnus Ahlkvist ·
Did you have failover on the cluster at the time or just before the time of these errors? You don't say if it's an always on availability group or a failover cluster instance, but it shouldn't make a huge difference.
If you didn't have a failover just before these errors, you might have had a short network glitch causing the connection to close. If you have connection pooling, it might be worth investigating if there's a way in the pool-software to check connection status and reconnect if needed when handing connection to the calling application.
I would like to use the sql command data access mode in an OLD DB Destination but I am not sure what my select statement would look like, in particular, do I reference a table name after say a fuzzy lookup was performed.