Class ClientConfig<T extends org.apache.avro.specific.SpecificRecord>

java.lang.Object
com.linkedin.venice.client.store.ClientConfig<T>

public class ClientConfig<T extends org.apache.avro.specific.SpecificRecord> extends Object
  • Field Details

    • DEFAULT_ZK_TIMEOUT_MS

      public static final int DEFAULT_ZK_TIMEOUT_MS
      See Also:
    • DEFAULT_CLUSTER_DISCOVERY_D2_SERVICE_NAME

      public static final String DEFAULT_CLUSTER_DISCOVERY_D2_SERVICE_NAME
      See Also:
    • DEFAULT_D2_ZK_BASE_PATH

      public static final String DEFAULT_D2_ZK_BASE_PATH
      See Also:
    • DEFAULT_SCHEMA_REFRESH_PERIOD

      public static final Duration DEFAULT_SCHEMA_REFRESH_PERIOD
  • Constructor Details

    • ClientConfig

      public ClientConfig()
    • ClientConfig

      public ClientConfig(String storeName)
  • Method Details

    • defaultGenericClientConfig

      public static ClientConfig defaultGenericClientConfig(String storeName)
    • defaultVsonGenericClientConfig

      @Deprecated public static ClientConfig defaultVsonGenericClientConfig(String storeName)
      Deprecated.
    • defaultSpecificClientConfig

      public static <V extends org.apache.avro.specific.SpecificRecord> ClientConfig<V> defaultSpecificClientConfig(String storeName, Class<V> specificValueClass)
    • cloneConfig

      public static <V extends org.apache.avro.specific.SpecificRecord> ClientConfig<V> cloneConfig(ClientConfig<V> config)
    • getStoreName

      public String getStoreName()
    • setStoreName

      public ClientConfig<T> setStoreName(String storeName)
    • isForceClusterDiscoveryAtStartTime

      public boolean isForceClusterDiscoveryAtStartTime()
    • setForceClusterDiscoveryAtStartTime

      public ClientConfig<T> setForceClusterDiscoveryAtStartTime(boolean forceClusterDiscoveryAtStartTime)
    • getVeniceURL

      public String getVeniceURL()
    • setVeniceURL

      public ClientConfig<T> setVeniceURL(String veniceURL)
      Parameters:
      veniceURL - If using D2, this should be D2 ZK address. Otherwise, it should be router address.
    • getStatsPrefix

      public String getStatsPrefix()
    • setStatsPrefix

      public ClientConfig<T> setStatsPrefix(String statsPrefix)
    • getSpecificValueClass

      public Class<T> getSpecificValueClass()
    • setSpecificValueClass

      public ClientConfig<T> setSpecificValueClass(Class<T> specificValueClass)
    • isSpecificClient

      public boolean isSpecificClient()
    • isD2Routing

      public boolean isD2Routing()
    • getD2ServiceName

      public String getD2ServiceName()
    • setD2ServiceName

      public ClientConfig<T> setD2ServiceName(String d2ServiceName)
    • getD2BasePath

      public String getD2BasePath()
    • setD2BasePath

      public ClientConfig<T> setD2BasePath(String d2BasePath)
    • getD2ZkTimeout

      public int getD2ZkTimeout()
    • setD2ZkTimeout

      public ClientConfig<T> setD2ZkTimeout(int d2ZkTimeout)
    • getD2Client

      public com.linkedin.d2.balancer.D2Client getD2Client()
    • setD2Client

      public ClientConfig<T> setD2Client(com.linkedin.d2.balancer.D2Client d2Client)
    • isHttps

      public boolean isHttps()
    • getSslFactory

      public SSLFactory getSslFactory()
    • setSslFactory

      public ClientConfig<T> setSslFactory(SSLFactory sslEngineComponentFactory)
    • getMaxConnectionsPerRoute

      public int getMaxConnectionsPerRoute()
    • setMaxConnectionsPerRoute

      public ClientConfig<T> setMaxConnectionsPerRoute(int maxConnectionsPerRoute)
    • getMaxConnectionsTotal

      public int getMaxConnectionsTotal()
    • setMaxConnectionsTotal

      public ClientConfig<T> setMaxConnectionsTotal(int maxConnectionsTotal)
    • isHttpClient5Http2Enabled

      public boolean isHttpClient5Http2Enabled()
    • setHttpClient5Http2Enabled

      public ClientConfig<T> setHttpClient5Http2Enabled(boolean httpClient5Http2Enabled)
    • getMetricsRepository

      public io.tehuti.metrics.MetricsRepository getMetricsRepository()
    • setMetricsRepository

      public ClientConfig<T> setMetricsRepository(io.tehuti.metrics.MetricsRepository metricsRepository)
    • getDeserializationExecutor

      public Executor getDeserializationExecutor()
    • setDeserializationExecutor

      public ClientConfig<T> setDeserializationExecutor(Executor deserializationExecutor)
      Provide an arbitrary executor to execute client requests in, rather than letting the client use its own internally-generated executor. If null, or unset, the client will use Executors.newFixedThreadPool(int) with a thread limit equal to half the CPU cores.
    • isVsonClient

      @Deprecated public boolean isVsonClient()
      Deprecated.
    • setVsonClient

      @Deprecated public ClientConfig<T> setVsonClient(boolean isVonClient)
      Deprecated.
    • getBatchGetDeserializer

      public BatchDeserializer getBatchGetDeserializer(Executor executor)
    • setBatchDeserializerType

      public ClientConfig<T> setBatchDeserializerType(BatchDeserializerType batchDeserializerType)
    • setMultiGetEnvelopeIterableImpl

      @Deprecated public ClientConfig<T> setMultiGetEnvelopeIterableImpl(AvroGenericDeserializer.IterableImpl multiGetEnvelopeIterableImpl)
      Deprecated.
    • setOnDemandDeserializerNumberOfRecordsPerThread

      @Deprecated public ClientConfig<T> setOnDemandDeserializerNumberOfRecordsPerThread(int onDemandDeserializerNumberOfRecordsPerThread)
      Deprecated.
    • setAlwaysOnDeserializerNumberOfThreads

      @Deprecated public ClientConfig<T> setAlwaysOnDeserializerNumberOfThreads(int alwaysOnDeserializerNumberOfThreads)
      Deprecated.
    • setAlwaysOnDeserializerQueueCapacity

      @Deprecated public ClientConfig<T> setAlwaysOnDeserializerQueueCapacity(int alwaysOnDeserializerQueueCapacity)
      Deprecated.
    • isUseFastAvro

      public boolean isUseFastAvro()
    • setUseFastAvro

      public ClientConfig<T> setUseFastAvro(boolean useFastAvro)
    • setRetryOnRouterError

      public ClientConfig<T> setRetryOnRouterError(boolean value)
    • isRetryOnRouterErrorEnabled

      public boolean isRetryOnRouterErrorEnabled()
    • setRetryOnAllErrors

      public ClientConfig<T> setRetryOnAllErrors(boolean value)
    • isRetryOnAllErrorsEnabled

      public boolean isRetryOnAllErrorsEnabled()
    • setRetryCount

      public ClientConfig<T> setRetryCount(int retryCount)
    • getRetryCount

      public int getRetryCount()
    • setRetryBackOffInMs

      public ClientConfig<T> setRetryBackOffInMs(long retryBackOffInMs)
    • getRetryBackOffInMs

      public long getRetryBackOffInMs()
    • getRetryExecutor

      public Executor getRetryExecutor()
    • setRetryExecutor

      public ClientConfig<T> setRetryExecutor(Executor retryExecutor)
    • isUseBlackHoleDeserializer

      public boolean isUseBlackHoleDeserializer()
    • setUseBlackHoleDeserializer

      public ClientConfig<T> setUseBlackHoleDeserializer(boolean useBlackHoleDeserializer)
    • isProjectionFieldValidationEnabled

      public boolean isProjectionFieldValidationEnabled()
    • setProjectionFieldValidationEnabled

      public ClientConfig<T> setProjectionFieldValidationEnabled(boolean projectionFieldValidation)
    • isRemoteComputationOnly

      public boolean isRemoteComputationOnly()
    • setRemoteComputationOnly

      public ClientConfig<T> setRemoteComputationOnly(boolean remoteComputationOnly)
    • getPreferredSchemaFilter

      public Optional<Predicate<org.apache.avro.Schema>> getPreferredSchemaFilter()
    • setPreferredSchemaFilter

      public ClientConfig<T> setPreferredSchemaFilter(Predicate<org.apache.avro.Schema> preferredSchemaFilter)
    • getSchemaRefreshPeriod

      public Duration getSchemaRefreshPeriod()
    • setSchemaRefreshPeriod

      public ClientConfig<T> setSchemaRefreshPeriod(Duration schemaRefreshPeriod)
    • getTime

      public io.tehuti.utils.Time getTime()
    • setTime

      public ClientConfig<T> setTime(io.tehuti.utils.Time time)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object