Search in sources :

Example 1 with TransactionStarter

use of com.palantir.lock.client.TransactionStarter in project atlasdb by palantir.

the class InMemoryTimelockServices method getLegacyTimelockService.

public TimelockService getLegacyTimelockService() {
    RequestBatchersFactory requestBatchersFactory = helperServices.requestBatchersFactory();
    TransactionStarter transactionStarter = TransactionStarter.create(lockLeaseService, requestBatchersFactory);
    CommitTimestampGetter commitTimestampGetter = requestBatchersFactory.createBatchingCommitTimestampGetter(lockLeaseService);
    NamespacedTimelockRpcClient namespacedTimelockRpcClient = new InMemoryNamespacedTimelockRpcClient(getTimelockService());
    return new RemoteTimelockServiceAdapter(namespacedTimelockRpcClient, namespacedConjureTimelockService, lockLeaseService, transactionStarter, commitTimestampGetter);
}
Also used : RemoteTimelockServiceAdapter(com.palantir.lock.client.RemoteTimelockServiceAdapter) RequestBatchersFactory(com.palantir.lock.client.RequestBatchersFactory) TransactionStarter(com.palantir.lock.client.TransactionStarter) CommitTimestampGetter(com.palantir.lock.client.CommitTimestampGetter) NamespacedTimelockRpcClient(com.palantir.lock.v2.NamespacedTimelockRpcClient)

Aggregations

CommitTimestampGetter (com.palantir.lock.client.CommitTimestampGetter)1 RemoteTimelockServiceAdapter (com.palantir.lock.client.RemoteTimelockServiceAdapter)1 RequestBatchersFactory (com.palantir.lock.client.RequestBatchersFactory)1 TransactionStarter (com.palantir.lock.client.TransactionStarter)1 NamespacedTimelockRpcClient (com.palantir.lock.v2.NamespacedTimelockRpcClient)1