java.lang.Object | |||
↳ | org.springframework.transaction.support.AbstractPlatformTransactionManager | ||
↳ | org.springframework.transaction.jta.JtaTransactionManager | ||
↳ | org.springframework.transaction.jta.OC4JJtaTransactionManager |
Special JtaTransactionManager
variant for Oracle OC4J (10.1.3 and higher).
Supports the full power of Spring's transaction definitions on OC4J's
transaction coordinator, beyond standard JTA: transaction names
and per-transaction isolation levels.
Uses OC4J's special begin(name)
method to start a JTA transaction,
in orderto make Spring-driven transactions visible in OC4J's transaction
monitor. In case of Spring's declarative transactions, the exposed name will
(by default) be the fully-qualified class name + "." + method name.
Supports a per-transaction isolation level through OC4J's corresponding
OC4JTransaction.setTransactionIsolation(int)
method. This will
apply the specified isolation level (e.g. ISOLATION_SERIALIZABLE) to all
JDBC Connections that participate in the given transaction.
Automatically detects the available OC4J server version and adapts accordingly. Supports the "com.evermind.server" package in OC4J 10.1.3.2 as well as the "oracle.j2ee.transaction" package in later OC4J versions.
By default, the JTA UserTransaction and TransactionManager handles are
fetched directly from OC4J's TransactionUtility
in 10.1.3.2+.
This can be overridden by specifying "userTransaction"/"userTransactionName"
and "transactionManager"/"transactionManagerName", passing in existing handles
or specifying corresponding JNDI locations to look up.
Thanks to Oracle for donating the original version of this extended OC4J integration code to the Spring project!
getName()
getIsolationLevel()
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.transaction.jta.JtaTransactionManager
| |||||||||||
From class
org.springframework.transaction.support.AbstractPlatformTransactionManager
|
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.transaction.jta.JtaTransactionManager
| |||||||||||
From class
org.springframework.transaction.support.AbstractPlatformTransactionManager
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Initialize the UserTransaction as well as the TransactionManager handle.
| |||||||||||
Create an active Transaction object based on the given name and timeout.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Perform a JTA begin on the JTA UserTransaction or TransactionManager.
| |||||||||||
Allows subclasses to retrieve the JTA UserTransaction in a vendor-specific manner.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.transaction.jta.JtaTransactionManager
| |||||||||||
From class
org.springframework.transaction.support.AbstractPlatformTransactionManager
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
org.springframework.beans.factory.InitializingBean
| |||||||||||
From interface
org.springframework.transaction.PlatformTransactionManager
| |||||||||||
From interface
org.springframework.transaction.jta.TransactionFactory
|
Initialize the UserTransaction as well as the TransactionManager handle.
TransactionSystemException |
---|
Create an active Transaction object based on the given name and timeout.
name | the transaction name (may be null ) |
---|---|
timeout | the transaction timeout (may be -1 for the default timeout) |
null
)NotSupportedException | |
---|---|
SystemException |
Perform a JTA begin on the JTA UserTransaction or TransactionManager.
This implementation only supports standard JTA functionality: that is, no per-transaction isolation levels and no transaction names. Can be overridden in subclasses, for specific JTA implementations.
Calls applyIsolationLevel
and applyTimeout
before invoking the UserTransaction's begin
method.
txObject | the JtaTransactionObject containing the UserTransaction |
---|---|
definition | TransactionDefinition instance, describing propagation behavior, isolation level, read-only flag, timeout, and transaction name |
NotSupportedException | |
---|---|
SystemException |
Allows subclasses to retrieve the JTA UserTransaction in a vendor-specific manner. Only called if no "userTransaction" or "userTransactionName" specified.
The default implementation simply returns null
.
null
if none foundTransactionSystemException |
---|