mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
Stops the profileId parameter pollution, enables to potentially use transaction label and runtime toggling of collecting transaction profiling detail.
28 lines
645 B
Java
28 lines
645 B
Java
package io.ebeaninternal.server.transaction;
|
|
|
|
import io.ebeaninternal.api.SpiTransaction;
|
|
|
|
import java.sql.Connection;
|
|
|
|
/**
|
|
* AutoCommit based TransactionManager.
|
|
* <p>
|
|
* Intended to be used if when autoCommit mode is desired.
|
|
*/
|
|
public class AutoCommitTransactionManager extends TransactionManager {
|
|
|
|
public AutoCommitTransactionManager(TransactionManagerOptions options) {
|
|
super(options);
|
|
}
|
|
|
|
/**
|
|
* Create an autoCommit based Transaction.
|
|
*/
|
|
@Override
|
|
protected SpiTransaction createTransaction(boolean explicit, Connection c, long id) {
|
|
|
|
return new AutoCommitJdbcTransaction(prefix + id, explicit, c, this);
|
|
}
|
|
|
|
}
|