public interface TransactionManager extends Closeable
| Modifier and Type | Method and Description |
|---|---|
Transaction |
begin()
Starts a new transaction.
|
void |
commit(Transaction tx)
Commits a transaction.
|
Transaction |
fence(byte[] tableName)
Creates a fence
Creates a fence and returns a
Transaction interface implementation that contains the fence information. |
void |
rollback(Transaction tx)
Aborts a transaction.
|
Transaction begin() throws TransactionException
Transaction interface implementation that will be used in TTable's methods for
doing operations on the transactional context defined by the returned object.TransactionException - in case of any issuesvoid commit(Transaction tx) throws RollbackException, TransactionException
RollbackException will be thrown.tx - transaction to be committed.RollbackException - thrown when transaction has conflicts with another transaction or when was marked
for rollback.TransactionException - in case of any issuesvoid rollback(Transaction tx) throws TransactionException
tx - transaction to be rolled-backTransactionException - in case of any issuesTransaction fence(byte[] tableName) throws TransactionException
Transaction interface implementation that contains the fence information.tableName - name of the table that requires a fenceTransactionException - in case of any issuesCopyright © 2011–2020 Apache Software Foundation. All rights reserved.