Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-7560

PushHttpMetricsReporter should not convert metric value to double

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 2.1.0
    • 2.1.0, 2.2.0
    • None
    • None

    Description

      Currently PushHttpMetricsReporter will convert value from KafkaMetric.metricValue() to double. This will not work for non-numerical metrics such as version in AppInfoParser whose value can be string. This has caused issue for PushHttpMetricsReporter which in turn caused system test kafkatest.tests.client.quota_test.QuotaTest.test_quota to fail with the following exception:  

       File "/opt/kafka-dev/tests/kafkatest/tests/client/quota_test.py", line 196, in validate     metric.value for k, metrics in producer.metrics(group='producer-metrics', name='outgoing-byte-rate', client_id=producer.client_id) for metric in metrics ValueError: max() arg is an empty sequence
      

      Since we allow metric value to be object, PushHttpMetricsReporter should also read metric value as object and pass it to the http server.

      Attachments

        Issue Links

          Activity

            People

              lindong Dong Lin
              enether Stanislav Kozlovski
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: