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

Metric metadata-age is reset on a failed update

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 0.9.0.0
    • None
    • None

    Description

      In org.apache.kafka.clients.Metadata there is a lastUpdate() method that returns the time the metadata was lasted updated. This is only called by metadata-age metric.

      However the lastRefreshMs is updated on a failed update (when MetadataResponse has not valid nodes). This is confusing since the metric's name suggests that it is a true reflection of the age of the current metadata. But the age might be reset by a failed update.

      Additionally, lastRefreshMs is not reset on a failed update due to no node being available. This seems slightly inconsistent, since one failure condition resets the metrics, but another one does not. Especially since both failure conditions do trigger the backoff (for the next attempt).

      I have not implemented a patch yet, because I am unsure what expected behavior is.

      Attachments

        1. KAFKA-2101.patch
          4 kB
          Tim Brooks

        Activity

          People

            timbrooks Tim Brooks
            timbrooks Tim Brooks
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: