Package com.couchbase.client.core.msg.kv
Class KvPingRequest
- java.lang.Object
-
- com.couchbase.client.core.msg.BaseRequest<R>
-
- com.couchbase.client.core.msg.kv.BaseKeyValueRequest<NoopResponse>
-
- com.couchbase.client.core.msg.kv.NoopRequest
-
- com.couchbase.client.core.msg.kv.KvPingRequest
-
- All Implemented Interfaces:
KeyValueRequest<NoopResponse>
,Request<NoopResponse>
,ScopedRequest
,TargetedRequest
public class KvPingRequest extends NoopRequest implements TargetedRequest
-
-
Constructor Summary
Constructors Constructor Description KvPingRequest(Duration timeout, CoreContext ctx, RetryStrategy retryStrategy, CollectionIdentifier identifier, NodeIdentifier target)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description KvPingResponse
decode(com.couchbase.client.core.deps.io.netty.buffer.ByteBuf response, KeyValueChannelContext ctx)
Decode the encoded response into its message representation.String
name()
The unique name of the request, usually related to the type but not necessarily.Map<String,Object>
serviceContext()
Returns contextual information for each individual service.NodeIdentifier
target()
Returns the node that should service this request, or null to let the service locator decide.-
Methods inherited from class com.couchbase.client.core.msg.kv.NoopRequest
encode, idempotent
-
Methods inherited from class com.couchbase.client.core.msg.kv.BaseKeyValueRequest
bucket, collectionIdentifier, encodedExternalKeyWithCollection, encodedKeyWithCollection, errorCode, indicateRejectedWithNotMyVbucket, key, nextOpaque, opaque, operationId, partition, partition, rejectedWithNotMyVbucket, serviceType
-
Methods inherited from class com.couchbase.client.core.msg.BaseRequest
absoluteTimeout, cancel, cancellationReason, cancelled, completed, context, createdAt, fail, failed, id, requestSpan, response, retryStrategy, succeed, succeeded, timeout, timeoutElapsed, timeoutRegistration
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.couchbase.client.core.msg.Request
absoluteTimeout, cancel, cancellationReason, cancelled, completed, context, createdAt, fail, failed, id, requestSpan, response, retryStrategy, succeed, succeeded, timeout, timeoutElapsed, timeoutRegistration
-
-
-
-
Constructor Detail
-
KvPingRequest
public KvPingRequest(Duration timeout, CoreContext ctx, RetryStrategy retryStrategy, CollectionIdentifier identifier, NodeIdentifier target)
-
-
Method Detail
-
decode
public KvPingResponse decode(com.couchbase.client.core.deps.io.netty.buffer.ByteBuf response, KeyValueChannelContext ctx)
Description copied from interface:KeyValueRequest
Decode the encoded response into its message representation.- Specified by:
decode
in interfaceKeyValueRequest<NoopResponse>
- Overrides:
decode
in classNoopRequest
- Parameters:
response
- the response to decode.- Returns:
- the decoded response as the generic type R.
-
target
public NodeIdentifier target()
Description copied from interface:Request
Returns the node that should service this request, or null to let the service locator decide.- Specified by:
target
in interfaceRequest<NoopResponse>
- Returns:
- (nullable)
-
serviceContext
public Map<String,Object> serviceContext()
Description copied from interface:Request
Returns contextual information for each individual service.- Specified by:
serviceContext
in interfaceRequest<NoopResponse>
- Overrides:
serviceContext
in classBaseKeyValueRequest<NoopResponse>
- Returns:
- the service context.
-
name
public String name()
Description copied from interface:Request
The unique name of the request, usually related to the type but not necessarily.The default implementation is derived from the class name (i.e. FooRequest => foo), but if that does not match up it should be overridden in the actual class.
- Specified by:
name
in interfaceRequest<NoopResponse>
- Overrides:
name
in classNoopRequest
- Returns:
- the name of the request type.
-
-