Class BaseMetricsConfig<T extends BaseMetricsConfig>

Type Parameters:
T - The type of the concrete configuration class extending this base class.
Direct Known Subclasses:
ClientMetricsConfig, MetricsConfig

public abstract class BaseMetricsConfig<T extends BaseMetricsConfig>
extends Object
Base class of configuration options specific to metrics collection.
  • Field Details

    • enabled

      protected boolean enabled
    • jmxConfig

      protected MetricsJmxConfig jmxConfig
    • collectionFrequencySeconds

      protected int collectionFrequencySeconds
  • Constructor Details

    • BaseMetricsConfig

      protected BaseMetricsConfig()
    • BaseMetricsConfig

      protected BaseMetricsConfig​(BaseMetricsConfig metricsConfig)
  • Method Details

    • setEnabled

      @Nonnull public T setEnabled​(boolean enabled)
      Sets whether metrics collection should be enabled for the node. If enabled, Hazelcast Management Center will be able to connect to this member. It's enabled by default.

      May be overridden by ClusterProperty.METRICS_ENABLED system property.

    • isEnabled

      public boolean isEnabled()
      Returns if metrics collection is enabled.
    • setJmxConfig

      @Nonnull public T setJmxConfig​(MetricsJmxConfig jmxConfig)
    • getJmxConfig

      @Nonnull public MetricsJmxConfig getJmxConfig()
    • setCollectionFrequencySeconds

      @Nonnull public T setCollectionFrequencySeconds​(int intervalSeconds)
      Sets the metrics collection frequency in seconds. The same interval is used for collection for Management Center and for JMX publisher. By default, metrics are collected every 5 seconds.

      May be overridden by ClusterProperty.METRICS_COLLECTION_FREQUENCY system property.

    • getCollectionFrequencySeconds

      public int getCollectionFrequencySeconds()
      Returns the metrics collection frequency in seconds.