java.lang.Object | ||
↳ | org.springframework.transaction.support.TransactionSynchronizationAdapter | |
↳ | org.springframework.jdbc.support.lob.SpringLobCreatorSynchronization |
Callback for resource cleanup at the end of a Spring transaction.
Invokes LobCreator.close()
to clean up temporary LOBs
that might have been created.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | LOB_CREATOR_SYNCHRONIZATION_ORDER | Order value for TransactionSynchronization objects that clean up LobCreators. |
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From interface
org.springframework.core.Ordered
| |||||||||||
From interface
org.springframework.transaction.support.TransactionSynchronization
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a SpringLobCreatorSynchronization for the given LobCreator.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Invoked after transaction commit/rollback.
| |||||||||||
Invoked before transaction commit/rollback.
| |||||||||||
Return the order value of this object, with a
higher value meaning greater in terms of sorting.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.transaction.support.TransactionSynchronizationAdapter
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
org.springframework.core.Ordered
| |||||||||||
From interface
org.springframework.transaction.support.TransactionSynchronization
|
Order value for TransactionSynchronization objects that clean up LobCreators. Return CONNECTION_SYNCHRONIZATION_ORDER - 200 to execute LobCreator cleanup before Hibernate Session (- 100) and JDBC Connection cleanup, if any.
Create a SpringLobCreatorSynchronization for the given LobCreator.
lobCreator | the LobCreator to close after transaction completion |
---|
Invoked after transaction commit/rollback. Can perform resource cleanup after transaction completion.
NOTE: The transaction will have been committed or rolled back already,
but the transactional resources might still be active and accessible. As a
consequence, any data access code triggered at this point will still "participate"
in the original transaction, allowing to perform some cleanup (with no commit
following anymore!), unless it explicitly declares that it needs to run in a
separate transaction. Hence: Use PROPAGATION_REQUIRES_NEW
for any transactional operation that is called from here.
status | completion status according to the STATUS_* constants |
---|
Invoked before transaction commit/rollback. Can perform resource cleanup before transaction completion.
This method will be invoked after beforeCommit
, even when
beforeCommit
threw an exception. This callback allows for
closing resources before transaction completion, for any outcome.
Return the order value of this object, with a higher value meaning greater in terms of sorting.
Normally starting with 0, with Integer.MAX_VALUE
indicating the greatest value. Same order values will result
in arbitrary positions for the affected objects.
Higher values can be interpreted as lower priority. As a consequence, the object with the lowest value has highest priority (somewhat analogous to Servlet "load-on-startup" values).