Modifier and Type | Method and Description |
---|---|
<R extends Response> |
Core.send(Request<R> request)
Sends a command into the core layer and registers the request with the timeout timer.
|
<R extends Response> |
Core.send(Request<R> request,
boolean registerForTimeout)
Sends a command into the core layer and allows to avoid timeout registration.
|
Modifier and Type | Method and Description |
---|---|
void |
Timer.register(Request<Response> request)
Registers the given request to be tracked with its timeout value.
|
void |
Timer.scheduleForRetry(Core core,
Request<? extends Response> request,
Duration runAfter)
Schedules a request to be retried after the given duration.
|
Modifier and Type | Method and Description |
---|---|
static <T,RES extends Response> |
ClassicHelper.newAsyncResponse(Request<RES> request,
CompletableFuture<T> future)
Returns a new async response whose cancellation task calls
Request.cancel(CancellationReason) . |
Modifier and Type | Method and Description |
---|---|
<R extends Request<? extends Response>> |
Endpoint.send(R request)
Sends the request into this
Endpoint . |
<R extends Request<? extends Response>> |
BaseEndpoint.send(R request) |
Modifier and Type | Class and Description |
---|---|
class |
CoreHttpResponse |
Modifier and Type | Method and Description |
---|---|
static CouchbaseException |
DefaultErrorUtil.keyValueStatusToException(KeyValueRequest<? extends Response> request,
Response response)
Maps common KV response status codes to their corresponding user-level exceptions.
|
Modifier and Type | Method and Description |
---|---|
static CouchbaseException |
DefaultErrorUtil.keyValueStatusToException(KeyValueRequest<? extends Response> request,
Response response)
Maps common KV response status codes to their corresponding user-level exceptions.
|
static CouchbaseException |
DefaultErrorUtil.keyValueStatusToException(KeyValueRequest<? extends Response> request,
ResponseStatus status,
KeyValueErrorContext ctx,
String defaultErrorString) |
static AuthenticationFailureException |
AuthenticationFailureException.onAuthError(Request<? extends Response> request,
Throwable cause)
Must only be called on an AUTHENTICATION_ERROR RetryReason.
|
Modifier and Type | Method and Description |
---|---|
static KeyValueErrorContext |
KeyValueErrorContext.completedRequest(KeyValueRequest<?> request,
Response response) |
Modifier and Type | Method and Description |
---|---|
protected Exception |
NonChunkedHttpMessageHandler.failRequestWith(com.couchbase.client.core.deps.io.netty.handler.codec.http.HttpResponseStatus status,
String content,
NonChunkedHttpRequest<Response> request)
To be implemented by children, should return the proper service exception type for each.
|
static void |
TracingUtils.setCommonKVSpanAttributes(RequestSpan span,
KeyValueRequest<Response> request)
Sets attributes that are usefully duplicated across multiple spans.
|
Modifier and Type | Method and Description |
---|---|
protected Exception |
NonChunkedEventingMessageHandler.failRequestWith(com.couchbase.client.core.deps.io.netty.handler.codec.http.HttpResponseStatus status,
String content,
NonChunkedHttpRequest<Response> request) |
Modifier and Type | Class and Description |
---|---|
class |
BaseRequest<R extends Response>
Base class for all
Requests . |
interface |
NonChunkedHttpRequest<R extends Response> |
interface |
Request<R extends Response>
Represents a
Request flowing through the client. |
Modifier and Type | Class and Description |
---|---|
class |
BaseResponse
The parent class for all responses passing through the SDK.
|
Modifier and Type | Method and Description |
---|---|
Request<? extends Response> |
RequestContext.request() |
Constructor and Description |
---|
RequestContext(CoreContext ctx,
Request<? extends Response> request) |
RequestContext(Core core,
long contextId,
CoreEnvironment environment,
Authenticator authenticator,
Request<? extends Response> request) |
Modifier and Type | Class and Description |
---|---|
class |
AnalyticsResponse |
Modifier and Type | Interface and Description |
---|---|
interface |
ChunkedResponse<H extends ChunkHeader,R extends ChunkRow,T extends ChunkTrailer>
Describes a full chunked response with its required sections.
|
Modifier and Type | Class and Description |
---|---|
class |
BaseKeyValueRequest<R extends Response>
The
BaseKeyValueRequest should be subclassed by all KeyValue requests since it
provides common ground for all of them (i.e. |
interface |
KeyValueRequest<R extends Response>
Main parent interface for all Key/Value requests.
|
class |
PredeterminedPartitionRequest<R extends Response>
Parent class for requests which have their partition already set at creation time.
|
Modifier and Type | Class and Description |
---|---|
class |
BaseManagerRequest<R extends Response>
Base class for the manager requests, mainly to define the service type in a uniform way.
|
interface |
ManagerRequest<R extends Response>
Parent interface for all requests going to the cluster manager.
|
Modifier and Type | Class and Description |
---|---|
class |
BucketConfigResponse |
class |
BucketConfigStreamingResponse |
class |
GenericManagerResponse |
Modifier and Type | Class and Description |
---|---|
class |
QueryResponse |
Modifier and Type | Class and Description |
---|---|
class |
SearchResponse |
Modifier and Type | Class and Description |
---|---|
class |
ViewResponse |
Modifier and Type | Method and Description |
---|---|
<R extends Request<? extends Response>> |
Node.send(R request)
Sends the request into this
Node . |
protected <R extends Request<? extends Response>> |
Node.sendIntoRetry(R request)
Retries the request.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
AnalyticsLocator.checkServiceNotAvailable(Request<? extends Response> request,
ClusterConfig config) |
protected boolean |
RoundRobinLocator.checkServiceNotAvailable(Request<? extends Response> request,
ClusterConfig config)
Can be overridden to check if a request should be cancelled immediately that the service is not
supported.
|
protected boolean |
ViewLocator.checkServiceNotAvailable(Request<? extends Response> request,
ClusterConfig config) |
void |
RoundRobinLocator.dispatch(Request<? extends Response> request,
List<Node> nodes,
ClusterConfig config,
CoreContext ctx) |
void |
KeyValueLocator.dispatch(Request<? extends Response> request,
List<Node> nodes,
ClusterConfig config,
CoreContext ctx) |
void |
Locator.dispatch(Request<? extends Response> request,
List<Node> nodes,
ClusterConfig config,
CoreContext ctx)
Given the environment and node information, the implementation locates the right set of
nodes and dispatches the request into them.
|
protected boolean |
RoundRobinLocator.nodeCanBeUsed(Node node,
Request<? extends Response> request,
ClusterConfig config)
This method can be overridden for additional per-node checks in addition to the service-type
based check already performed in
RoundRobinLocator.filterNodes(List, Request, ClusterConfig) . |
protected boolean |
ViewLocator.nodeCanBeUsed(Node node,
Request<? extends Response> request,
ClusterConfig config)
In addition to checking that the view service is enabled, for view dispatching it is vital that
a request is only ever sent to a node which has active primary KV partitions.
|
Modifier and Type | Method and Description |
---|---|
static Duration |
RetryOrchestrator.capDuration(Duration uncappedDuration,
Request<? extends Response> request)
Calculates the potentially capped retry duration so we do not schedule a longer retry than the actual
total timeout.
|
static void |
RetryOrchestrator.maybeRetry(CoreContext ctx,
Request<? extends Response> request,
RetryReason reason)
Retry or cancel the given request, depending on its state and the configured
RetryStrategy . |
CompletableFuture<RetryAction> |
FailFastRetryStrategy.shouldRetry(Request<? extends Response> request,
RetryReason reason) |
CompletableFuture<RetryAction> |
BestEffortRetryStrategy.shouldRetry(Request<? extends Response> request,
RetryReason reason)
Determines if a request should be retried or not (and if so, after which duration).
|
CompletableFuture<RetryAction> |
RetryStrategy.shouldRetry(Request<? extends Response> request,
RetryReason reason)
Checks if the given request should be retried and how long the
retry delay should be.
|
Modifier and Type | Method and Description |
---|---|
<R extends Request<? extends Response>> |
EndpointSelectionStrategy.select(R request,
List<Endpoint> endpoints)
|
<R extends Request<? extends Response>> |
Service.send(R request)
Sends the request into this
Service . |
Modifier and Type | Method and Description |
---|---|
<R extends Request<? extends Response>> |
PartitionSelectionStrategy.select(R request,
List<Endpoint> endpoints) |
<R extends Request<? extends Response>> |
RoundRobinSelectionStrategy.select(R request,
List<Endpoint> endpoints) |
Modifier and Type | Class and Description |
---|---|
class |
CoreTransactionResponse |
Copyright © 2024 Couchbase, Inc.. All rights reserved.