org.eclipse.persistence.internal.jpa.transaction.EntityTransactionImpl
| Modifier and Type | Class and Description |
|---|---|
| pack-priv class |
| Modifier and Type | Field and Description |
|---|---|
| protected boolean | |
| protected EntityTransactionImpl. | |
| public static boolean | isFinalizedRequired
PERF: Avoid finalization if not required by the application, and finalizers have major concurrency affects. |
| protected WeakHashMap | openQueriesMap
Keep a weak reference to the open queries that are executed in this entity manager. |
| protected boolean | |
| protected EntityTransactionWrapper |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addOpenQuery(QueryImpl query)
Queries that leave the connection and are executed against this entity manager will be added here. |
| public void | |
| protected void | closeOpenQueries()
Open queries within a transaction will be closed on commit or rollback if they haven't already been closed. |
| public void | commit()
Implements jakarta. |
| protected Map | |
| public boolean | getRollbackOnly()
Implements jakarta. |
| public boolean | isActive()
Implements jakarta. |
| public void | rollback()
Implements jakarta. |
| public void | setRollbackOnly()
Implements jakarta. |
| active | back to summary |
|---|---|
| protected boolean active | |
| finalizer | back to summary |
|---|---|
| protected EntityTransactionImpl. | |
| isFinalizedRequired | back to summary |
|---|---|
| public static boolean isFinalizedRequired PERF: Avoid finalization if not required by the application, and finalizers have major concurrency affects. | |
| openQueriesMap | back to summary |
|---|---|
| protected WeakHashMap<QueryImpl, QueryImpl> openQueriesMap Keep a weak reference to the open queries that are executed in this entity manager. | |
| rollbackOnly | back to summary |
|---|---|
| protected boolean rollbackOnly | |
| wrapper | back to summary |
|---|---|
| protected EntityTransactionWrapper wrapper | |
| EntityTransactionImpl | back to summary |
|---|---|
| public EntityTransactionImpl(EntityTransactionWrapper wrapper) | |
| addOpenQuery | back to summary |
|---|---|
| public void addOpenQuery(QueryImpl query) Queries that leave the connection and are executed against this entity manager will be added here. On rollback or commit any left over open queries should be closed. | |
| begin | back to summary |
|---|---|
| public void begin() Implements jakarta. Start the current transaction. This can only be invoked if
| |
| closeOpenQueries | back to summary |
|---|---|
| protected void closeOpenQueries() Open queries within a transaction will be closed on commit or rollback if they haven't already been closed. | |
| commit | back to summary |
|---|---|
| public void commit() Implements jakarta. Commit the current transaction, writing any un-flushed changes to the
database. This can only be invoked if
| |
| getOpenQueriesMap | back to summary |
|---|---|
| protected Map Return the weak reference to the open queries. | |
| getRollbackOnly | back to summary |
|---|---|
| public boolean getRollbackOnly() Implements jakarta. Determine whether the current transaction has been marked for rollback.
| |
| isActive | back to summary |
|---|---|
| public boolean isActive() Implements jakarta. Check to see if the current transaction is in progress.
| |
| rollback | back to summary |
|---|---|
| public void rollback() Implements jakarta. Roll back the current transaction, discarding any changes that have
happened in this transaction. This can only be invoked if
| |
| setRollbackOnly | back to summary |
|---|---|
| public void setRollbackOnly() Implements jakarta. Mark the current transaction so that the only possible outcome of the transaction is for the transaction to be rolled back.
| |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| protected void | finalize()
Overrides java. |
| TransactionFinalizer | back to summary |
|---|---|
| pack-priv TransactionFinalizer() | |
| finalize | back to summary |
|---|---|
| protected void finalize() throws Throwable Overrides java. Here incase a user does not commit or rollback an enityTransaction but just throws it away. If we do not rollback the txn the connection will go back into the pool.
| |