Interface SolrMetricProducer

    • Method Detail

      • initializeMetrics

        default void initializeMetrics​(SolrMetricManager manager,
                                       String registry,
                                       String tag,
                                       String scope)
        Initializes metrics specific to this producer.

        Note: for back-compatibility this method by default calls initializeMetrics(SolrMetricManager, String, String).

        Parameters:
        manager - an instance of SolrMetricManager
        registry - registry name where metrics are registered
        tag - symbolic tag that represents a group of related instances that have the same life-cycle. Parent component can use the tag when calling SolrMetricManager.unregisterGauges(String, String) to unregister metrics created by this instance of the producer.
        scope - scope of the metrics (eg. handler name) to separate metrics of instances of the same component executing in different contexts
      • initializeMetrics

        @Deprecated
        default void initializeMetrics​(SolrMetricManager manager,
                                       String registry,
                                       String scope)
        Deprecated.
        this method doesn't provide enough context to properly manage life-cycle of some metrics (see SOLR-11882). Instead use initializeMetrics(SolrMetricManager, String, String, String).
        Initializes metrics specific to this producer.

        Note: for back-compatibility this method has a default no-op implementation.

        Parameters:
        manager - an instance of SolrMetricManager
        registry - registry name where metrics are registered
        scope - scope of the metrics (eg. handler name) to separate metrics of instances of the same component executing in different contexts