[
https://jira.jboss.org/jira/browse/JBTM-441?page=com.atlassian.jira.plugi...
]
John Mazzitelli updated JBTM-441:
---------------------------------
Attachment: AppServerJDBCXARecovery.java
see attached AppServerJDBCXARecovery.java that i'm using.
I confirmed that this does two things:
1) survives when the data source is not yet deployed (therefore, addresses JBTM-442 also)
2) survives if the connection under the covers goes bad
Note that this attempts to use the JRE 1.6 API "isValid" method to attempt to
check to see if the connection is still valid. If it is still valid, it reuses the
connection. If it is not valid, it will throw the connection away. But if the isValid
method isn't even supported (running on JDK 1.5 or the supporting implementation
classes do not support it), this flags the datasource as "not supporting" this
feature and will thereafter re-create the connection every time, never trying to validate
the connection.
AppServerJDBCXARecovery does not cope with stale connections
------------------------------------------------------------
Key: JBTM-441
URL:
https://jira.jboss.org/jira/browse/JBTM-441
Project: JBoss Transaction Manager
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Application Server Integration
Affects Versions: 4.2.3.SP7, 4.2.3.CP02
Reporter: Jonathan Halliday
Assignee: Jonathan Halliday
Fix For: 4.2.3.SP8, 4.2.3.CP03
Attachments: AppServerJDBCXARecovery.java
If the db bounces whilst the app server stays up, the AppServerJDBCXARecovery is left
holding an invalid connection, which causes XAResource on it to throw spurious errors. It
should refresh the connection on every call, or at least check it for validity before
handing out an XAResource based on it.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira