Search in sources :

Example 1 with TransactionRecoverTrackerImpl

use of org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl in project pulsar by yahoo.

the class TransactionMetadataStoreService method openTransactionMetadataStore.

public CompletableFuture<TransactionMetadataStore> openTransactionMetadataStore(TransactionCoordinatorID tcId) {
    return pulsarService.getBrokerService().getManagedLedgerConfig(getMLTransactionLogName(tcId)).thenCompose(v -> {
        TransactionTimeoutTracker timeoutTracker = timeoutTrackerFactory.newTracker(tcId);
        TransactionRecoverTracker recoverTracker = new TransactionRecoverTrackerImpl(TransactionMetadataStoreService.this, timeoutTracker, tcId.getId());
        return transactionMetadataStoreProvider.openStore(tcId, pulsarService.getManagedLedgerFactory(), v, timeoutTracker, recoverTracker);
    });
}
Also used : TransactionRecoverTrackerImpl(org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl) TransactionRecoverTracker(org.apache.pulsar.transaction.coordinator.TransactionRecoverTracker) TransactionTimeoutTracker(org.apache.pulsar.transaction.coordinator.TransactionTimeoutTracker)

Example 2 with TransactionRecoverTrackerImpl

use of org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl in project incubator-pulsar by apache.

the class TransactionMetadataStoreService method openTransactionMetadataStore.

public CompletableFuture<TransactionMetadataStore> openTransactionMetadataStore(TransactionCoordinatorID tcId) {
    return pulsarService.getBrokerService().getManagedLedgerConfig(getMLTransactionLogName(tcId)).thenCompose(v -> {
        TransactionTimeoutTracker timeoutTracker = timeoutTrackerFactory.newTracker(tcId);
        TransactionRecoverTracker recoverTracker = new TransactionRecoverTrackerImpl(TransactionMetadataStoreService.this, timeoutTracker, tcId.getId());
        return transactionMetadataStoreProvider.openStore(tcId, pulsarService.getManagedLedgerFactory(), v, timeoutTracker, recoverTracker);
    });
}
Also used : TransactionRecoverTrackerImpl(org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl) TransactionRecoverTracker(org.apache.pulsar.transaction.coordinator.TransactionRecoverTracker) TransactionTimeoutTracker(org.apache.pulsar.transaction.coordinator.TransactionTimeoutTracker)

Example 3 with TransactionRecoverTrackerImpl

use of org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl in project pulsar by apache.

the class TransactionMetadataStoreService method openTransactionMetadataStore.

public CompletableFuture<TransactionMetadataStore> openTransactionMetadataStore(TransactionCoordinatorID tcId) {
    return pulsarService.getBrokerService().getManagedLedgerConfig(getMLTransactionLogName(tcId)).thenCompose(v -> {
        TransactionTimeoutTracker timeoutTracker = timeoutTrackerFactory.newTracker(tcId);
        TransactionRecoverTracker recoverTracker = new TransactionRecoverTrackerImpl(TransactionMetadataStoreService.this, timeoutTracker, tcId.getId());
        return transactionMetadataStoreProvider.openStore(tcId, pulsarService.getManagedLedgerFactory(), v, timeoutTracker, recoverTracker);
    });
}
Also used : TransactionRecoverTrackerImpl(org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl) TransactionRecoverTracker(org.apache.pulsar.transaction.coordinator.TransactionRecoverTracker) TransactionTimeoutTracker(org.apache.pulsar.transaction.coordinator.TransactionTimeoutTracker)

Aggregations

TransactionRecoverTrackerImpl (org.apache.pulsar.broker.transaction.recover.TransactionRecoverTrackerImpl)3 TransactionRecoverTracker (org.apache.pulsar.transaction.coordinator.TransactionRecoverTracker)3 TransactionTimeoutTracker (org.apache.pulsar.transaction.coordinator.TransactionTimeoutTracker)3