Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-14837

prometheus-exporter: different metrics ports publishes mixed metrics

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Patch Available
    • Minor
    • Resolution: Unresolved
    • 8.6.2
    • None
    • None

    Description

      when calling SolrExporter.main "pro-grammatically"/"same JVM" with two different solr masters asking to publish the metrics on two different ports, the metrics are being mixed on both metric endpoints from the two solr masters.

      This was tracked down to a static variable called defaultRegistry:
      https://github.com/apache/lucene-solr/blob/master/solr/contrib/prometheus-exporter/src/java/org/apache/solr/prometheus/exporter/SolrExporter.java#L86

      removing the static keyword fixes the issue.

      Attachments

        1. SOLR-14837.patch
          17 kB
          Fadi Mohsen

        Activity

          People

            Unassigned Unassigned
            fadi.mohsen@gmail.com Fadi Mohsen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: