About Transaction

161-170 of 200Refresh
JPA Doc
3

getSingleResult()

has been set and there is no transaction PessimisticLockException - if pessimistic locking fails and the transaction is rolled back LockTimeoutException - if pessimistic locking fails and only the statement is rolled back PersistenceException - if the query execution exceeds the query timeout value set and the transaction is rolled back Since: JPA 2.0
JDO Doc
3

getTransactionalObjectId(pc)

. If the object identity is being changed in the transaction, by the application modifying one or more of the application key fields, then this method returns the current identity in the transaction. If there is no transaction in progress, or if none of the key fields is being modified
JDO Doc
3

isTransactional(pc)

Static Method javax.jdo.JDOHelper boolean isTransactional(   Object pc ) Tests whether the parameter instance is transactional. Instances whose state is associated with the current transaction return ... is transactional. Since: JDO 1.0 See Also: PersistenceCapable.jdoIsTransactional()
JPA Doc
3

javax.persistence.PersistenceContext

PersistenceContextType type (Optional) Specifies whether a transaction-scoped persistence context or an extended persistence context is to be used. (Optional) Specifies whether a transaction-scoped ... .PersistenceContextType.TRANSACTION Since: JPA 1.0 String unitName (Optional) The name
JDO Doc
3

jdoIsTransactional()

Method javax.jdo.spi.PersistenceCapable boolean jdoIsTransactional() Tests whether this object is transactional. Instances whose state is associated with the current transaction return true. Transient instances return false. Returns: true if this instance is transactional. Since: JDO 1.0
JPA Doc
3

lock(entity, lockMode)

if the database locking failure causes transaction-level rollback the LockTimeoutException will be thrown ... is a detached entity TransactionRequiredException - if there is no transaction EntityNotFoundException ... fails and the transaction is rolled back LockTimeoutException - if pessimistic locking fails
JPA Doc
3

lock(entity, lockMode, properties)

transaction-level rollback the LockTimeoutException will be thrown if the database locking failure causes ... is a detached entity TransactionRequiredException - if there is no transaction EntityNotFoundException ... and the transaction is rolled back LockTimeoutException - if pessimistic locking fails
JDO Doc
3

makeNontransactional(pc)

Method javax.jdo.PersistenceManager void makeNontransactional(   Object pc ) Make an instance non-transactional after commit. Normally, at transaction completion, instances are evicted from the cache ... at transaction completion. Instead, the instance remains in the cache with nontransactional state
JDO Doc
3

refreshAll()

Method javax.jdo.PersistenceManager void refreshAll() Refresh the state of all applicable instances from the data store. If called with an active transaction, all transactional instances will be refreshed. If called outside an active transaction, all nontransactional instances will be refreshed. Since: JDO 1.0 See Also: refresh(Object pc)
JPA Doc
3

setRollbackOnly()

Method javax.persistence.EntityTransaction void setRollbackOnly() Mark the current resource transaction so that the only possible outcome of the transaction is for the transaction to be rolled back. Throws: IllegalStateException - if isActive() is false Since: JPA 1.0