Class ClientProperty

java.lang.Object
com.hazelcast.client.properties.ClientProperty

public final class ClientProperty extends Object
Defines the name and default value for Hazelcast Client properties.
  • Field Details

    • SHUFFLE_MEMBER_LIST

      public static final HazelcastProperty SHUFFLE_MEMBER_LIST
      Client shuffles the given member list to prevent all clients to connect to the same node when this property is set to true. When it is set to false, the client tries to connect to the nodes in the given order.
    • HEARTBEAT_TIMEOUT

      public static final HazelcastProperty HEARTBEAT_TIMEOUT
      Client sends heartbeat messages to the members and this is the timeout for this sending operations. If there is not any message passing between the client and member within the given time via this property in milliseconds, the connection will be closed.
    • EVENT_QUEUE_CAPACITY

      public static final HazelcastProperty EVENT_QUEUE_CAPACITY
      Capacity of the executor that handles the incoming event packets.
    • EVENT_THREAD_COUNT

      public static final HazelcastProperty EVENT_THREAD_COUNT
      Number of the threads to handle the incoming event packets.
    • HEARTBEAT_INTERVAL

      public static final HazelcastProperty HEARTBEAT_INTERVAL
      Time interval between the heartbeats sent by the client to the nodes.
    • INVOCATION_TIMEOUT_SECONDS

      public static final HazelcastProperty INVOCATION_TIMEOUT_SECONDS
      When an invocation gets an exception because: - Member throws an exception. - Connection between the client and member is closed. - Client's heartbeat requests are timed out. - SQL query resubmission timed out. Time passed since invocation started is compared with this property. If the time is already passed, then the exception is delegated to the user. If not, the invocation is retried. Note that if invocation gets no exception, and it is a long-running one, then it will not get any exception, no matter how small this timeout is set.
    • INVOCATION_RETRY_PAUSE_MILLIS

      public static final HazelcastProperty INVOCATION_RETRY_PAUSE_MILLIS
      Pause time between each retry cycle of an invocation in milliseconds.
    • MAX_CONCURRENT_INVOCATIONS

      public static final HazelcastProperty MAX_CONCURRENT_INVOCATIONS
      The maximum number of concurrent invocations allowed.

      To prevent the system from overloading, user can apply a constraint on the number of concurrent invocations. If the maximum number of concurrent invocations has been exceeded and a new invocation comes in, then hazelcast will throw HazelcastOverloadException

      By default, it is configured as Integer.MaxValue.

    • BACKPRESSURE_BACKOFF_TIMEOUT_MILLIS

      public static final HazelcastProperty BACKPRESSURE_BACKOFF_TIMEOUT_MILLIS
      Control the maximum timeout in millis to wait for an invocation space to be available.

      If an invocation can't be made because there are too many pending invocations, then an exponential backoff is done to give the system time to deal with the backlog of invocations. This property controls how long an invocation is allowed to wait before getting a HazelcastOverloadException.

      When set to -1 then HazelcastOverloadException is thrown immediately without any waiting.

    • IO_INPUT_THREAD_COUNT

      public static final HazelcastProperty IO_INPUT_THREAD_COUNT
      Controls the number of IO input threads. Defaults to -1, so the system will decide.

      If client uses RoutingMode.ALL_MEMBERS routing and processor count larger than 8, it will default to 3 otherwise it defaults to 1.

    • IO_OUTPUT_THREAD_COUNT

      public static final HazelcastProperty IO_OUTPUT_THREAD_COUNT
      Controls the number of IO output threads. Defaults to -1, so the system will decide.

      If client use RoutingMode.ALL_MEMBERS routing and processor count larger than 8 , it will default to 3 otherwise it defaults to 1.

    • IO_BALANCER_INTERVAL_SECONDS

      public static final HazelcastProperty IO_BALANCER_INTERVAL_SECONDS
      The interval in seconds between IOBalancer executions. The shorter intervals will catch I/O Imbalance faster, but they will cause higher overhead.

      Please see the documentation of IOBalancer for a detailed explanation of the problem.

      The default is 20 seconds. A value smaller than 1 disables the balancer.

    • IO_WRITE_THROUGH_ENABLED

      public static final HazelcastProperty IO_WRITE_THROUGH_ENABLED
      Optimization that allows sending of packets over the network to be done on the calling thread if the conditions are right. This can reduce latency and increase performance for low threaded environments.

      It is enabled by default.

    • CONCURRENT_WINDOW_MS

      public static final HazelcastProperty CONCURRENT_WINDOW_MS
      Property needed for concurrency detection so that write through and dynamic response handling can be done correctly. This property sets the window the concurrency detection will signalling that concurrency has been detected, even if there are no further updates in that window.

      Normally in a concurrent system the window keeps sliding forward so it will always remain concurrent.

      Setting it too high effectively disables the optimization because once concurrency has been detected it will keep that way. Setting it too low could lead to suboptimal performance because the system will try to write through and other optimizations even though the system is concurrent.

    • RESPONSE_THREAD_COUNT

      public static final HazelcastProperty RESPONSE_THREAD_COUNT
      The number of response threads.

      By default there are 2 response threads; this gives stable and good performance.

      If set to 0, the response threads are bypassed and the response handling is done on the IO threads. Under certain conditions this can give a higher throughput, but setting to 0 should be regarded an experimental feature.

      If set to 0, the IO_OUTPUT_THREAD_COUNT is really going to matter because the inbound thread will have more work to do. By default, when TLS isn't enable, there is just 1 inbound thread.

    • RESPONSE_THREAD_DYNAMIC

      public static final HazelcastProperty RESPONSE_THREAD_DYNAMIC
      Enabled dynamic switching between processing responses on the io threads and offloading the response threads.

      Under certain conditions (single threaded clients) processing on the io thread can increase performance because useless handover to the response thread is removed. Also the response thread isn't created until it is needed and especially for ephemeral clients reducing threads can lead to increased performance and reduced memory usage.

    • OPERATION_BACKUP_TIMEOUT_MILLIS

      public static final HazelcastProperty OPERATION_BACKUP_TIMEOUT_MILLIS
      If an operation has backups, this property specifies how long the invocation will wait for acks from the backup replicas. If acks are not received from some backups, there will not be any rollback on other successful replicas.
    • FAIL_ON_INDETERMINATE_OPERATION_STATE

      public static final HazelcastProperty FAIL_ON_INDETERMINATE_OPERATION_STATE
      When this configuration is enabled, if an operation has sync backups and acks are not received from backup replicas in time, or the member which owns primary replica of the target partition leaves the cluster, then the invocation fails with IndeterminateOperationStateException. However, even if the invocation fails, there will not be any rollback on other successful replicas.
    • STATISTICS_PERIOD_SECONDS

      @Deprecated public static final HazelcastProperty STATISTICS_PERIOD_SECONDS
      Deprecated.
      since 4.0. Use { #METRICS_COLLECTION_FREQUENCY} ("hazelcast.client.metrics.collection.frequency") instead.
      The period in seconds the statistics run.

      The values set here is used as {#METRICS_COLLECTION_FREQUENCY} as instead. If both this and {#METRICS_COLLECTION_FREQUENCY} are configured, this is ignored.

    • PARTITIONING_STRATEGY_CLASS

      public static final HazelcastProperty PARTITIONING_STRATEGY_CLASS
      Class name implementing PartitioningStrategy, which defines key to partition mapping. Client-side equivalent of member property ClusterProperty.PARTITIONING_STRATEGY_CLASS.

      This property does not contain the "hazelcast.client" prefix as has been used on the client with this property name for over 8 years, so it is maintained for backwards compatibility.

    • DISCOVERY_SPI_ENABLED

      public static final HazelcastProperty DISCOVERY_SPI_ENABLED

      Enables the Discovery SPI

      Discovery SPI is disabled by default

    • DISCOVERY_SPI_PUBLIC_IP_ENABLED

      public static final HazelcastProperty DISCOVERY_SPI_PUBLIC_IP_ENABLED

      Enables the Discovery Joiner to use public IP from DiscoveredNode.

      Discovery SPI is disabled by default

    • CLIENT_CONNECTIVITY_LOGGING_DELAY_SECONDS

      public static final HazelcastProperty CLIENT_CONNECTIVITY_LOGGING_DELAY_SECONDS
      Sets the client connectivity logging delay in seconds. This value dictates the delay between a connectivity stat of clients to cluster members.

      The delay is intended to reduce noise from frequent connection updates that may occur in bursts. Note that the latest connectivity view will be logged when the task is run. For more, see ClientConnectivityLogger

    • METRICS_ENABLED

      public static final HazelcastProperty METRICS_ENABLED
      Enables/disables metrics collection altogether. This is a master switch for all metrics related functionality.

      NOTE: This property overrides BaseMetricsConfig.isEnabled().

      Using BaseMetricsConfig.setEnabled(boolean) and the declarative counterparts are preferred over using this property. The main purpose of making metrics collection configurable from properties too is allowing operators to configure the metrics subsystem from the outside during investigation without touching or copying the configuration potentially embedded into a signed artifact.

    • METRICS_DEBUG

      public static final HazelcastProperty METRICS_DEBUG
      Enables collecting debug metrics. Debug metrics are sent to the diagnostics only.
    • METRICS_JMX_ENABLED

      public static final HazelcastProperty METRICS_JMX_ENABLED
      Enables/disables exposing metrics on JMX.

      NOTE: This property overrides MetricsJmxConfig.isEnabled().

      Using MetricsJmxConfig.setEnabled(boolean) and the declarative counterparts are preferred over using this property. The main purpose of making metrics collection configurable from properties too is allowing operators to configure the metrics subsystem from the outside during investigation without touching or copying the configuration potentially embedded into a signed artifact.

    • METRICS_COLLECTION_FREQUENCY

      public static final HazelcastProperty METRICS_COLLECTION_FREQUENCY
      Sets the metrics collection frequency in seconds.

      NOTE: This property overrides BaseMetricsConfig.getCollectionFrequencySeconds().

      Using BaseMetricsConfig.setCollectionFrequencySeconds(int) and the declarative counterparts are preferred over using this property. The main purpose of making metrics collection configurable from properties too is allowing operators to configure the metrics subsystem from the outside during investigation without touching or copying the configuration potentially embedded into a signed artifact.

    • STATISTICS_ENABLED

      @Deprecated public static final HazelcastProperty STATISTICS_ENABLED
      Deprecated.
      since 4.0. Use METRICS_ENABLED ("hazelcast.client.metrics.enabled") instead.
      Enables the client statistics collection.

      The default is false.

      Setting this enables Metrics since 4.0.

      If both this and METRICS_ENABLED are configured, this is ignored.

      Note that when this is enabled, the default value of METRICS_COLLECTION_FREQUENCY (5 seconds) will be used instead of STATISTICS_PERIOD_SECONDS (3 seconds), when not set explicitly.