Class ConfluenceSynchronizationManager
java.lang.Object
com.atlassian.confluence.impl.transaction.ConfluenceSynchronizationManager
- All Implemented Interfaces:
SynchronizationManager,SynchronizationManagerInternal
public class ConfluenceSynchronizationManager
extends Object
implements SynchronizationManagerInternal
Confluence transaction sycnhronization manager. Uses Spring for transaction management.
- Since:
- 9.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidregisterSynchronization(org.springframework.transaction.support.TransactionSynchronization synchronization) Registers a SpringTransactionSynchronizationon the current transaction.voidRegister a task to be run once the current transaction is successfully committed.
-
Constructor Details
-
ConfluenceSynchronizationManager
public ConfluenceSynchronizationManager()
-
-
Method Details
-
runOnSuccessfulCommit
Register a task to be run once the current transaction is successfully committed. If no transaction exists the task is run immediately. All tasks are run on the thread which registered them.
If a task produces an exception it is logged and swallowed.
- Specified by:
runOnSuccessfulCommitin interfaceSynchronizationManager- See Also:
-
isTransactionActive
public boolean isTransactionActive()- Specified by:
isTransactionActivein interfaceSynchronizationManager- Returns:
- true if there is an active Spring transaction which accepts synchronizations, otherwise false.
-
registerSynchronization
public void registerSynchronization(org.springframework.transaction.support.TransactionSynchronization synchronization) Description copied from interface:SynchronizationManagerInternalRegisters a SpringTransactionSynchronizationon the current transaction.- Specified by:
registerSynchronizationin interfaceSynchronizationManagerInternal
-