Jason Gustafson created KAFKA-9939:
--------------------------------------

             Summary: Fetch request metrics are updated twice for delayed 
fetches
                 Key: KAFKA-9939
                 URL: https://issues.apache.org/jira/browse/KAFKA-9939
             Project: Kafka
          Issue Type: Bug
            Reporter: Jason Gustafson
            Assignee: Jason Gustafson


We track fetch request rate metrics in `BrokerTopicStats`. We have both topic 
level and total metrics. Currently these values are updated in 
`ReplicaManager.readFromLocalLog`. Inside `fetchMessages`, we invoke 
`readFromLocalLog` first to see if the fetch can be immediately satisfied. If 
not, then we put it in purgatory. After completing purgatory, we make a second 
call to `readFromLocalLog` which will again update the request rate metrics. 
Hence we are overcounting the fetch request rate.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to