Interface TransactionMetadataStoreProvider
- All Known Implementing Classes:
InMemTransactionMetadataStoreProvider,MLTransactionMetadataStoreProvider
@Beta
public interface TransactionMetadataStoreProvider
A provider that provides
TransactionMetadataStore.-
Method Summary
Modifier and TypeMethodDescriptionnewProvider(String providerClassName) Construct a provider from the provided class.openStore(TransactionCoordinatorID transactionCoordinatorId, ManagedLedgerFactory managedLedgerFactory, ManagedLedgerConfig managedLedgerConfig, TransactionTimeoutTracker timeoutTracker, TransactionRecoverTracker recoverTracker, long maxActiveTransactionsPerCoordinator, TxnLogBufferedWriterConfig txnLogBufferedWriterConfig, io.netty.util.Timer timer) Open the transaction metadata store for transaction coordinator identified by transactionCoordinatorId.
-
Method Details
-
newProvider
Construct a provider from the provided class.- Parameters:
providerClassName- the provider class name.- Returns:
- an instance of transaction metadata store provider.
- Throws:
IOException
-
openStore
CompletableFuture<TransactionMetadataStore> openStore(TransactionCoordinatorID transactionCoordinatorId, ManagedLedgerFactory managedLedgerFactory, ManagedLedgerConfig managedLedgerConfig, TransactionTimeoutTracker timeoutTracker, TransactionRecoverTracker recoverTracker, long maxActiveTransactionsPerCoordinator, TxnLogBufferedWriterConfig txnLogBufferedWriterConfig, io.netty.util.Timer timer) Open the transaction metadata store for transaction coordinator identified by transactionCoordinatorId.- Parameters:
transactionCoordinatorId-TransactionCoordinatorIDthe coordinator id.managedLedgerFactory-ManagedLedgerFactorythe managedLedgerFactory to create managedLedger.managedLedgerConfig-ManagedLedgerConfigthe managedLedgerConfig to create managedLedger.timeoutTracker-TransactionTimeoutTrackerthe timeoutTracker to handle transaction time out.recoverTracker-TransactionRecoverTrackerthe recoverTracker to handle transaction recover.- Returns:
- a future represents the result of the operation.
an instance of
TransactionMetadataStoreis returned if the operation succeeds.
-