public class TransactionRecoveryImpl extends java.lang.Object implements TransactionRecovery
Constructor and Description |
---|
TransactionRecoveryImpl()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
forget()
close Transaction Recovery Log
|
JotmRecovery |
getJotmRecovery() |
java.util.Vector |
getRmRegistration() |
static TransactionRecoveryImpl |
getTransactionRecovery()
Returns the unique instance of the class or
null if not
initialized in case of plain client. |
org.objectweb.howl.log.xa.XACommittingTx |
howlCommitLog(byte[][] xaCmRec)
write the Commit record to the Howl Log
|
void |
howlDoneLog(byte[][] xaDnRec,
org.objectweb.howl.log.xa.XACommittingTx xaCmTx)
write the Done record to the Howl Log
|
void |
logNewResourceManagerRM1(java.lang.String rmName,
javax.transaction.xa.XAResource xaRes,
java.lang.String xaresName)
Log a ResourceManager
|
void |
recoverResourceManager()
Recover a Resource Manager with the JOTM Transaction Manager.
|
void |
registerResourceManager(java.lang.String rmName,
javax.transaction.xa.XAResource rmXares,
java.lang.String info,
java.util.Properties rmProperties,
TransactionResourceManager trm)
Register a Resource Manager with the JOTM Transaction Manager.
|
void |
registerResourceManager(java.lang.String rmName,
javax.transaction.xa.XAResource rmXares,
java.lang.String info,
TransactionResourceManager tranrm)
Register a Resource Manager with the JOTM Transaction Manager.
|
javax.transaction.xa.XAResource |
reportResourceManager(java.lang.String rmName)
Provide information regarding the status and state of the XAResource.
|
void |
startResourceManagerRecovery()
Log (in Howl) every Resource Manager (XAResource) that has been
registered.
|
void |
unregisterResourceManager(java.lang.String rmName,
javax.transaction.xa.XAResource rmXares)
Unregister a Resource Manager from the JOTM Transaction Manager.
|
public static TransactionRecoveryImpl getTransactionRecovery()
null
if not
initialized in case of plain client.TransactionRecovery
object createdpublic JotmRecovery getJotmRecovery()
getJotmRecovery
in interface TransactionRecovery
public java.util.Vector getRmRegistration()
getRmRegistration
in interface TransactionRecovery
public void registerResourceManager(java.lang.String rmName, javax.transaction.xa.XAResource rmXares, java.lang.String info, java.util.Properties rmProperties, TransactionResourceManager trm) throws javax.transaction.xa.XAException
registerResourceManager
in interface TransactionRecovery
rmName
- The Resource Manager to be registered.rmXares
- XAResource associated with the Resource Managerinfo
- String of information for display with admin interfacermProperties
- - Strings specifying recovery properties for resourcetrm
- TransactionResourceManager to return the registered XAResourcejavax.transaction.xa.XAException
- if an error occurspublic void registerResourceManager(java.lang.String rmName, javax.transaction.xa.XAResource rmXares, java.lang.String info, TransactionResourceManager tranrm) throws javax.transaction.xa.XAException
TransactionRecovery
registerResourceManager
in interface TransactionRecovery
rmName
- The Resource Manager to be registered.rmXares
- XAResource associated with the Resource Managerinfo
- String of information for display with admin interfacetranrm
- TransactionResourceManager to return the registered XAResourcejavax.transaction.xa.XAException
- if an error occurspublic javax.transaction.xa.XAResource reportResourceManager(java.lang.String rmName) throws javax.transaction.xa.XAException
reportResourceManager
in interface TransactionRecovery
rmName
- The Resource Manager to be reported upon.javax.transaction.xa.XAException
- if an error occurspublic void unregisterResourceManager(java.lang.String rmName, javax.transaction.xa.XAResource rmXares) throws javax.transaction.xa.XAException
unregisterResourceManager
in interface TransactionRecovery
rmName
- The Resource Manager to be unregistered.rmXares
- XAResource associated with the Resource Managerjavax.transaction.xa.XAException
- if an error occurspublic void startResourceManagerRecovery() throws javax.transaction.xa.XAException
startResourceManagerRecovery
in interface TransactionRecovery
javax.transaction.xa.XAException
- Thrown if the transaction manager
encounters an unexpected error conditionpublic void logNewResourceManagerRM1(java.lang.String rmName, javax.transaction.xa.XAResource xaRes, java.lang.String xaresName) throws javax.transaction.xa.XAException
rmName
- ResourceManager namexaRes
- XAResourcexaresName
- name of the XAResourcejavax.transaction.xa.XAException
- Cannot write the logpublic void recoverResourceManager() throws javax.transaction.xa.XAException
javax.transaction.xa.XAException
- Thrown if the transaction manager
encounters an unexpected error conditionpublic org.objectweb.howl.log.xa.XACommittingTx howlCommitLog(byte[][] xaCmRec) throws org.objectweb.howl.log.LogException, java.io.IOException, java.lang.InterruptedException
xaCmRec
- the Commit Recordorg.objectweb.howl.log.LogException
- could not log the recordjava.io.IOException
java.lang.InterruptedException
public void howlDoneLog(byte[][] xaDnRec, org.objectweb.howl.log.xa.XACommittingTx xaCmTx) throws org.objectweb.howl.log.LogException, java.io.IOException, java.lang.InterruptedException
xaDnRec
- the Done RecordxaCmTx
- the XACommittingTxorg.objectweb.howl.log.LogException
- could not log the recordjava.io.IOException
java.lang.InterruptedException
public void forget() throws org.objectweb.howl.log.LogException, javax.transaction.SystemException
forget
in interface TransactionRecovery
org.objectweb.howl.log.LogException
javax.transaction.SystemException