R - the generic type of the response.public interface KeyValueRequest<R extends Response> extends Request<R>, ScopedRequest
| Modifier and Type | Method and Description |
|---|---|
CollectionIdentifier |
collectionIdentifier() |
R |
decode(com.couchbase.client.core.deps.io.netty.buffer.ByteBuf response,
KeyValueChannelContext ctx)
Decode the encoded response into its message representation.
|
com.couchbase.client.core.deps.io.netty.buffer.ByteBuf |
encode(com.couchbase.client.core.deps.io.netty.buffer.ByteBufAllocator alloc,
int opaque,
KeyValueChannelContext ctx)
Encode this request with the given allocator and opaque.
|
void |
errorCode(ErrorMap.ErrorCode errorCode)
Sets the error code on the request for debugging purposes.
|
void |
indicateRejectedWithNotMyVbucket()
Increments the counter indicating that this request has been rejected with a not my vbucket response.
|
byte[] |
key()
The key of the kv request.
|
int |
opaque() |
short |
partition()
Reads the currently set partition this request is targeted against.
|
void |
partition(short partition)
Allows to set the partition used for this request.
|
int |
rejectedWithNotMyVbucket()
Returns the number of times this request has been rejected with a not my vbucket response before.
|
absoluteTimeout, bucket, cancel, cancel, cancellationReason, cancelled, completed, context, createdAt, fail, failed, id, idempotent, name, operationId, requestSpan, response, retryStrategy, serviceContext, serviceType, succeed, succeeded, target, timeout, timeoutElapsed, timeoutRegistrationshort partition()
void partition(short partition)
partition - the partition to set.com.couchbase.client.core.deps.io.netty.buffer.ByteBuf encode(com.couchbase.client.core.deps.io.netty.buffer.ByteBufAllocator alloc,
int opaque,
KeyValueChannelContext ctx)
alloc - the allocator where to grab the buffers from.opaque - the opaque value to use.ctx - more encode context.ByteBuf.R decode(com.couchbase.client.core.deps.io.netty.buffer.ByteBuf response, KeyValueChannelContext ctx)
response - the response to decode.byte[] key()
CollectionIdentifier collectionIdentifier()
int opaque()
int rejectedWithNotMyVbucket()
void indicateRejectedWithNotMyVbucket()
void errorCode(ErrorMap.ErrorCode errorCode)
errorCode - the error code to set for the request.Copyright © 2024 Couchbase, Inc.. All rights reserved.