public class WASManagedRuntime extends AbstractManagedRuntime implements ManagedRuntime, Configurable
ManagedRuntime implementation that allows synchronization with a
WebSphere managed transaction.
WebSphere Application Server does not expose the TransactionManager to an application. Instead it provides a proprietary interface to register for synchronization and obtain transaction ids.
WASManagedRuntime provides the wrapper classes needed to interact with the WAS proprietary interface and the OpenJPA kernel.
| Constructor and Description |
|---|
WASManagedRuntime() |
| Modifier and Type | Method and Description |
|---|---|
void |
endConfiguration()
EndConfiguration stub.
|
Throwable |
getRollbackCause()
Returns the Throwable that caused the current transaction to be
marked for rollback, provided that any exists.
|
TransactionManager |
getTransactionManager()
Gets an extendedJTATransaction from JNDI and creates a transaction
wrapper
|
static void |
main(String[] args) |
void |
setConfiguration(Configuration conf)
Caches a copy of the configuration.
|
void |
setRollbackOnly(Throwable cause)
Sets the rollback only flag on the current transaction.
|
void |
startConfiguration()
StartConfiguration stub.
|
doNonTransactionalWork, getTransactionKeyclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdoNonTransactionalWork, getTransactionKeypublic TransactionManager getTransactionManager() throws Exception
getTransactionManager in interface ManagedRuntimeExceptionpublic void setConfiguration(Configuration conf)
setConfiguration in interface Configurablepublic void endConfiguration()
endConfiguration in interface Configurablepublic void startConfiguration()
startConfiguration in interface Configurablepublic static void main(String[] args) throws IOException
IOExceptionpublic void setRollbackOnly(Throwable cause) throws Exception
ManagedRuntimesetRollbackOnly in interface ManagedRuntimecause - the Throwable that caused the transaction to be
marked for rollback, or null of none is knownExceptionpublic Throwable getRollbackCause() throws Exception
ManagedRuntimegetRollbackCause in interface ManagedRuntimeExceptionCopyright © 2006–2022 Apache Software Foundation. All rights reserved.