Class GenericViewRequest

java.lang.Object
com.couchbase.client.core.msg.BaseRequest<GenericViewResponse>
com.couchbase.client.core.msg.view.GenericViewRequest
All Implemented Interfaces:
Encodable<com.couchbase.client.core.deps.io.netty.handler.codec.http.FullHttpRequest>, NonChunkedHttpRequest<GenericViewResponse>, Request<GenericViewResponse>, ScopedRequest

public class GenericViewRequest
extends BaseRequest<GenericViewResponse>
implements NonChunkedHttpRequest<GenericViewResponse>, ScopedRequest
  • Constructor Details

    • GenericViewRequest

      public GenericViewRequest​(Duration timeout, CoreContext ctx, RetryStrategy retryStrategy, Supplier<com.couchbase.client.core.deps.io.netty.handler.codec.http.FullHttpRequest> requestSupplier, boolean idempotent, String bucket)
  • Method Details

    • decode

      public GenericViewResponse decode​(com.couchbase.client.core.deps.io.netty.handler.codec.http.FullHttpResponse response, HttpChannelContext context)
      Specified by:
      decode in interface NonChunkedHttpRequest<GenericViewResponse>
    • encode

      public com.couchbase.client.core.deps.io.netty.handler.codec.http.FullHttpRequest encode()
      Specified by:
      encode in interface Encodable<com.couchbase.client.core.deps.io.netty.handler.codec.http.FullHttpRequest>
    • serviceType

      public ServiceType serviceType()
      Description copied from interface: Request
      The service type of this request.
      Specified by:
      serviceType in interface Request<GenericViewResponse>
      Returns:
      the service type for this request.
    • bucket

      public String bucket()
      Specified by:
      bucket in interface ScopedRequest
    • idempotent

      public boolean idempotent()
      Description copied from interface: Request
      Returns if the given request is idempotent or not.

      By default, this method always returns false for data consistency reasons. Only specific idempotent operations should override this default since it impacts retry handling quite a bit. DO NOT SET THIS TO TRUE ON MUTATING OPERATIONS!

      Specified by:
      idempotent in interface Request<GenericViewResponse>
      Returns:
      true if idempotent.