Module org.jooq
Package org.jooq

Interface TransactionProvider

All Known Implementing Classes:
DefaultTransactionProvider, NoTransactionProvider, ThreadLocalTransactionProvider

public interface TransactionProvider
The TransactionProvider SPI can be used to implement custom transaction behaviour that is applied when calling DSLContext.transactionResult(TransactionalCallable) or DSLContext.transaction(TransactionalRunnable).

A new Configuration copy is created from the calling DSLContext for the scope of a single transactions. Implementors may freely add custom data to Configuration.data(), in order to share information between begin(TransactionContext) and commit(TransactionContext) or rollback(TransactionContext), as well as to share information with nested transactions.

Implementors may freely choose whether they support nested transactions. An example implementation supporting nested transactions is DefaultTransactionProvider, which implements such transactions using JDBC Savepoints.

Author:
Lukas Eder