allow override of begin transaction
Closes #31005 Signed-off-by: Baljit Singh <baljit.singh@verizon.com>
This commit is contained in:
parent
2da37542e8
commit
94934d1ad4
1 changed files with 3 additions and 2 deletions
|
@ -17,8 +17,6 @@
|
|||
|
||||
package org.keycloak.models;
|
||||
|
||||
import org.jboss.logging.Logger;
|
||||
|
||||
/**
|
||||
* Handles some common transaction logic related to start, rollback-only etc.
|
||||
*
|
||||
|
@ -34,6 +32,8 @@ public abstract class AbstractKeycloakTransaction implements KeycloakTransaction
|
|||
throw new IllegalStateException("Transaction already started");
|
||||
}
|
||||
|
||||
beginImpl();
|
||||
|
||||
state = TransactionState.STARTED;
|
||||
}
|
||||
|
||||
|
@ -82,6 +82,7 @@ public abstract class AbstractKeycloakTransaction implements KeycloakTransaction
|
|||
NOT_STARTED, STARTED, ROLLBACK_ONLY, FINISHED
|
||||
}
|
||||
|
||||
protected void beginImpl() {}
|
||||
|
||||
protected abstract void commitImpl();
|
||||
|
||||
|
|
Loading…
Reference in a new issue