|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atomikos.datasource.xa.XATransactionalResource com.atomikos.datasource.xa.jdbc.JdbcTransactionalResource
public class JdbcTransactionalResource
A default XATransactionalResource implementation for JDBC.
Field Summary |
---|
Fields inherited from class com.atomikos.datasource.xa.XATransactionalResource |
---|
recoveryMap_, servername_, siblingmappers_, xares_, xidFact_ |
Constructor Summary | |
---|---|
JdbcTransactionalResource(String serverName,
XADataSource xads)
Constructs a new instance with a given name and XADataSource. |
|
JdbcTransactionalResource(String serverName,
XADataSource xads,
XidFactory factory)
Constructs a new instance with a given name and XADataSource, and an Xid factory to use. |
Method Summary | |
---|---|
void |
close()
Overrides default close to include closing any open connections to the XADataSource. |
protected XAResource |
refreshXAConnection()
Implements the functionality to get an XAResource handle. |
void |
setPassword(String password)
Optionally set the password with which to get connections for recovery. |
void |
setUser(String user)
Optionally set the user name with which to get connections for recovery. |
Methods inherited from class com.atomikos.datasource.xa.XATransactionalResource |
---|
acceptsAllXAResources, createXid, endRecovery, getName, getResourceTransaction, getXAResource, getXidFactory, isClosed, isSameRM, needsRefresh, printMsg, recover, recover, setAcceptAllXAResources, setRecoveryService, setXidFactory, usesWeakCompare, usesXAResource, useWeakCompare |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JdbcTransactionalResource(String serverName, XADataSource xads)
serverName
- The unique name.xads
- The data source.public JdbcTransactionalResource(String serverName, XADataSource xads, XidFactory factory)
serverName
- The unique name.xads
- The data source.factory
- The custom Xid factory.Method Detail |
---|
protected XAResource refreshXAConnection() throws ResourceException
refreshXAConnection
in class XATransactionalResource
ResourceException
- On failure.public void setUser(String user)
user
- The user name.public void setPassword(String password)
password
- The password.public void close() throws ResourceException
close
in interface RecoverableResource
close
in class XATransactionalResource
ResourceException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |