Search in sources :

Example 6 with Errors

use of io.etcd.jetcd.support.Errors in project jetcd by coreos.

the class LockImpl method unlock.

@Override
public CompletableFuture<UnlockResponse> unlock(ByteSequence lockKey) {
    checkNotNull(lockKey);
    UnlockRequest request = UnlockRequest.newBuilder().setKey(Util.prefixNamespace(lockKey, namespace)).build();
    return execute(() -> stub.unlock(request), UnlockResponse::new, Errors::isRetryable);
}
Also used : Errors(io.etcd.jetcd.support.Errors) UnlockResponse(io.etcd.jetcd.lock.UnlockResponse) UnlockRequest(io.etcd.jetcd.api.lock.UnlockRequest)

Aggregations

Errors (io.etcd.jetcd.support.Errors)6 CompactionRequest (io.etcd.jetcd.api.CompactionRequest)1 LockRequest (io.etcd.jetcd.api.lock.LockRequest)1 UnlockRequest (io.etcd.jetcd.api.lock.UnlockRequest)1 CompactResponse (io.etcd.jetcd.kv.CompactResponse)1 DeleteResponse (io.etcd.jetcd.kv.DeleteResponse)1 GetResponse (io.etcd.jetcd.kv.GetResponse)1 PutResponse (io.etcd.jetcd.kv.PutResponse)1 LockResponse (io.etcd.jetcd.lock.LockResponse)1 UnlockResponse (io.etcd.jetcd.lock.UnlockResponse)1