public class MLTransactionLogImpl extends Object implements TransactionLog
| Modifier and Type | Field and Description |
|---|---|
static String |
TRANSACTION_LOG_PREFIX |
| Constructor and Description |
|---|
MLTransactionLogImpl(TransactionCoordinatorID tcID,
ManagedLedgerFactory managedLedgerFactory,
ManagedLedgerConfig managedLedgerConfig) |
| Modifier and Type | Method and Description |
|---|---|
CompletableFuture<Position> |
append(TransactionMetadataEntry transactionMetadataEntry)
Append the transaction operation to the transaction log.
|
CompletableFuture<Void> |
closeAsync()
Close the transaction log.
|
CompletableFuture<Void> |
deletePosition(List<Position> positions) |
CompletableFuture<Long> |
getMaxLocalTxnId() |
void |
replayAsync(TransactionLogReplayCallback transactionLogReplayCallback)
Replay transaction log to load the transaction map.
|
public static final String TRANSACTION_LOG_PREFIX
public MLTransactionLogImpl(TransactionCoordinatorID tcID, ManagedLedgerFactory managedLedgerFactory, ManagedLedgerConfig managedLedgerConfig) throws Exception
Exceptionpublic void replayAsync(TransactionLogReplayCallback transactionLogReplayCallback)
TransactionLogreplayAsync in interface TransactionLogtransactionLogReplayCallback - the call back for replaying the transaction logpublic CompletableFuture<Void> closeAsync()
TransactionLogcloseAsync in interface TransactionLogpublic CompletableFuture<Position> append(TransactionMetadataEntry transactionMetadataEntry)
TransactionLogappend in interface TransactionLogtransactionMetadataEntry - TransactionMetadataEntry transaction metadata entrypublic CompletableFuture<Void> deletePosition(List<Position> positions)
public CompletableFuture<Long> getMaxLocalTxnId()
Copyright © 2017–2021 Apache Software Foundation. All rights reserved.