Class IoConfig

java.lang.Object
com.couchbase.client.core.env.IoConfig

public class IoConfig extends Object
  • Field Details

    • DEFAULT_MUTATION_TOKENS_ENABLED

      public static final boolean DEFAULT_MUTATION_TOKENS_ENABLED
      See Also:
    • DEFAULT_DNS_SRV_ENABLED

      public static final boolean DEFAULT_DNS_SRV_ENABLED
      See Also:
    • DEFAULT_TCP_KEEPALIVE_ENABLED

      public static final boolean DEFAULT_TCP_KEEPALIVE_ENABLED
      See Also:
    • DEFAULT_TCP_KEEPALIVE_TIME

      public static final Duration DEFAULT_TCP_KEEPALIVE_TIME
    • DEFAULT_TCP_KEEPALIVE_INTERVAL

      public static final Duration DEFAULT_TCP_KEEPALIVE_INTERVAL
    • DEFAULT_TCP_KEEPALIVE_COUNT

      public static final int DEFAULT_TCP_KEEPALIVE_COUNT
      See Also:
    • DEFAULT_TCP_USER_TIMEOUT

      public static final Duration DEFAULT_TCP_USER_TIMEOUT
    • DEFAULT_CONFIG_POLL_INTERVAL

      public static final Duration DEFAULT_CONFIG_POLL_INTERVAL
    • DEFAULT_NETWORK_RESOLUTION

      public static final NetworkResolution DEFAULT_NETWORK_RESOLUTION
    • DEFAULT_NUM_KV_CONNECTIONS

      public static final int DEFAULT_NUM_KV_CONNECTIONS
      See Also:
    • DEFAULT_MAX_HTTP_CONNECTIONS

      public static final int DEFAULT_MAX_HTTP_CONNECTIONS
      See Also:
    • DEFAULT_IDLE_HTTP_CONNECTION_TIMEOUT

      public static final Duration DEFAULT_IDLE_HTTP_CONNECTION_TIMEOUT
    • DEFAULT_CONFIG_IDLE_REDIAL_TIMEOUT

      public static final Duration DEFAULT_CONFIG_IDLE_REDIAL_TIMEOUT
    • DEFAULT_MEMCACHED_HASHING_STRATEGY

      public static final MemcachedHashingStrategy DEFAULT_MEMCACHED_HASHING_STRATEGY
  • Method Details

    • create

      @Deprecated public static IoConfig create()
      Deprecated.
      Instead, please use CoreEnvironment.Builder.ioConfig(Consumer) and configure the builder passed to the consumer. Note: CoreEnvironment is a base class; you'll probably call that method via a subclass named ClusterEnvironment.
    • builder

      @Deprecated public static IoConfig.Builder builder()
      Deprecated.
      Instead of creating a new builder, please use CoreEnvironment.Builder.ioConfig(Consumer) and configure the builder passed to the consumer. Note: CoreEnvironment is a base class; you'll probably call that method via a subclass named ClusterEnvironment.
    • enableMutationTokens

      @Deprecated public static IoConfig.Builder enableMutationTokens(boolean mutationTokensEnabled)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • enableDnsSrv

      @Deprecated public static IoConfig.Builder enableDnsSrv(boolean dnsSrvEnabled)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • configPollInterval

      @Deprecated public static IoConfig.Builder configPollInterval(Duration configPollInterval)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • kvCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder kvCircuitBreakerConfig(CircuitBreakerConfig.Builder kvCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • queryCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder queryCircuitBreakerConfig(CircuitBreakerConfig.Builder queryCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • viewCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder viewCircuitBreakerConfig(CircuitBreakerConfig.Builder viewCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • searchCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder searchCircuitBreakerConfig(CircuitBreakerConfig.Builder searchCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • analyticsCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder analyticsCircuitBreakerConfig(CircuitBreakerConfig.Builder analyticsCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • managerCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder managerCircuitBreakerConfig(CircuitBreakerConfig.Builder managerCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • eventingCircuitBreakerConfig

      @Deprecated public static IoConfig.Builder eventingCircuitBreakerConfig(CircuitBreakerConfig.Builder eventingCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • backupCircuitBreakerConfig

      @Deprecated @Volatile public static IoConfig.Builder backupCircuitBreakerConfig(CircuitBreakerConfig.Builder backupCircuitBreakerConfig)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • captureTraffic

      @Deprecated public static IoConfig.Builder captureTraffic(ServiceType... serviceTypes)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
      Captures the traffic for all services provided as an argument (all if empty).

      IMPORTANT: It is not enough to just enable traffic capturing, also TRACE level logging needs to be enabled for the couchbase namespace in your logger implementation.

      Note that this flag should only be enabled during development and for debugging purposes. When enabled it will add more overhead due to traffic parsing, logging and analysis.

      Returns:
      this IoConfig.Builder for chaining purposes.
    • networkResolution

      @Deprecated public static IoConfig.Builder networkResolution(NetworkResolution networkResolution)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • enableTcpKeepAlives

      @Deprecated public static IoConfig.Builder enableTcpKeepAlives(boolean tcpKeepAliveEnabled)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • tcpKeepAliveTime

      @Deprecated public static IoConfig.Builder tcpKeepAliveTime(Duration tcpKeepAliveTime)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • numKvConnections

      @Deprecated public static IoConfig.Builder numKvConnections(int numKvConnections)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • maxHttpConnections

      @Deprecated public static IoConfig.Builder maxHttpConnections(int maxHttpConnections)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • idleHttpConnectionTimeout

      @Deprecated public static IoConfig.Builder idleHttpConnectionTimeout(Duration idleHttpConnectionTimeout)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • configIdleRedialTimeout

      @Deprecated public static IoConfig.Builder configIdleRedialTimeout(Duration configIdleRedialTimeout)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
    • memcachedHashingStrategy

      @Deprecated public static IoConfig.Builder memcachedHashingStrategy(MemcachedHashingStrategy memcachedHashingStrategy)
      Deprecated.
      This method creates a new builder. Please see the deprecation notice on builder().
      Allows to customize the hashing strategy for memcached buckets.

      Usually the MemcachedHashingStrategy should only be customized if i.e. the SDK is upgraded from Java SDK 2 and the documents in the bucket must be preserved. In this case, the Sdk2CompatibleMemcachedHashingStrategy must be chosen. If it is used though, keep in mind that it is not compatible with other SDKs, so we always recommend to use the default StandardMemcachedHashingStrategy by default.

      Parameters:
      memcachedHashingStrategy - the strategy to use.
      Returns:
      this IoConfig.Builder for chaining purposes.
    • kvCircuitBreakerConfig

      public CircuitBreakerConfig kvCircuitBreakerConfig()
    • queryCircuitBreakerConfig

      public CircuitBreakerConfig queryCircuitBreakerConfig()
    • viewCircuitBreakerConfig

      public CircuitBreakerConfig viewCircuitBreakerConfig()
    • searchCircuitBreakerConfig

      public CircuitBreakerConfig searchCircuitBreakerConfig()
    • analyticsCircuitBreakerConfig

      public CircuitBreakerConfig analyticsCircuitBreakerConfig()
    • managerCircuitBreakerConfig

      public CircuitBreakerConfig managerCircuitBreakerConfig()
    • eventingCircuitBreakerConfig

      public CircuitBreakerConfig eventingCircuitBreakerConfig()
    • backupCircuitBreakerConfig

      @Volatile public CircuitBreakerConfig backupCircuitBreakerConfig()
    • mutationTokensEnabled

      public boolean mutationTokensEnabled()
    • dnsSrvEnabled

      public boolean dnsSrvEnabled()
    • configPollInterval

      public Duration configPollInterval()
    • servicesToCapture

      public Set<ServiceType> servicesToCapture()
      Lists the services on which traffic should be captured.
      Returns:
      the services to capture traffic from, if present.
    • networkResolution

      public NetworkResolution networkResolution()
    • tcpKeepAlivesEnabled

      public boolean tcpKeepAlivesEnabled()
    • tcpKeepAliveTime

      public Duration tcpKeepAliveTime()
    • tcpKeepAliveInterval

      public Duration tcpKeepAliveInterval()
    • tcpKeepAliveCount

      public int tcpKeepAliveCount()
    • tcpUserTimeout

      public Duration tcpUserTimeout()
    • numKvConnections

      public int numKvConnections()
    • maxHttpConnections

      public int maxHttpConnections()
    • idleHttpConnectionTimeout

      public Duration idleHttpConnectionTimeout()
    • configIdleRedialTimeout

      public Duration configIdleRedialTimeout()
    • memcachedHashingStrategy

      public MemcachedHashingStrategy memcachedHashingStrategy()
    • timerConfig

      @Volatile public TimerConfig timerConfig()