Class WebSphereExtendedJtaPlatform
- java.lang.Object
-
- org.hibernate.engine.transaction.jta.platform.internal.AbstractJtaPlatform
-
- org.hibernate.engine.transaction.jta.platform.internal.WebSphereExtendedJtaPlatform
-
- All Implemented Interfaces:
Serializable,TransactionManagerAccess,JtaPlatform,Service,Configurable,ServiceRegistryAwareService
public class WebSphereExtendedJtaPlatform extends AbstractJtaPlatform
JTA platform implementation intended for use with WebSphere Application Server (WAS).WAS, unlike every other app server on the planet, does not allow direct access to the JTS TransactionManager. Instead, for common transaction-related tasks users must utilize a proprietary API known as ExtendedJTATransaction.
Even more unfortunate, the exact TransactionManagerLookup to use inside of WAS is highly dependent upon
- WAS version
- the WAS container in which Hibernate will be utilized
This class is reported to work on WAS version 6 in any of the standard J2EE/Java EE component containers.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classWebSphereExtendedJtaPlatform.TransactionManagerAdapter
-
Constructor Summary
Constructors Constructor Description WebSphereExtendedJtaPlatform()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancanCacheTransactionManager()ObjectgetTransactionIdentifier(Transaction transaction)Determine an identifier for the given transaction appropriate for use in caching/lookup usages.protected TransactionManagerlocateTransactionManager()protected UserTransactionlocateUserTransaction()-
Methods inherited from class org.hibernate.engine.transaction.jta.platform.internal.AbstractJtaPlatform
canCacheTransactionManagerByDefault, canCacheUserTransaction, canCacheUserTransactionByDefault, canRegisterSynchronization, configure, getCurrentStatus, getSynchronizationStrategy, getTransactionManager, injectServices, jndiService, registerSynchronization, retrieveTransactionManager, retrieveUserTransaction, serviceRegistry
-
-
-
-
Field Detail
-
UT_NAME
public static final String UT_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
canCacheTransactionManager
protected boolean canCacheTransactionManager()
- Overrides:
canCacheTransactionManagerin classAbstractJtaPlatform
-
locateTransactionManager
protected TransactionManager locateTransactionManager()
- Specified by:
locateTransactionManagerin classAbstractJtaPlatform
-
locateUserTransaction
protected UserTransaction locateUserTransaction()
- Specified by:
locateUserTransactionin classAbstractJtaPlatform
-
getTransactionIdentifier
public Object getTransactionIdentifier(Transaction transaction)
Description copied from interface:JtaPlatformDetermine an identifier for the given transaction appropriate for use in caching/lookup usages.Generally speaking the transaction itself will be returned here. This method was added specifically for use in WebSphere and other unfriendly Java EE containers.
- Specified by:
getTransactionIdentifierin interfaceJtaPlatform- Overrides:
getTransactionIdentifierin classAbstractJtaPlatform- Parameters:
transaction- The transaction to be identified.- Returns:
- An appropriate identifier
-
-