You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "hudeqi (via GitHub)" <gi...@apache.org> on 2023/04/01 10:08:24 UTC

[GitHub] [kafka] hudeqi commented on pull request #13471: KAFKA-14868:Remove some forgotten metrics when the replicaManager is closed

hudeqi commented on PR #13471:
URL: https://github.com/apache/kafka/pull/13471#issuecomment-1492912261

   > @hudeqi please feel free to cherry-pick this commit: [divijvaidya@e6db8ea](https://github.com/divijvaidya/kafka/commit/e6db8eaaeffc3b7a87f34c0e72ff25395fda97a3) into this PR.
   > 
   > It introduces the unit test which fails before the `removeMetrics()` and passes after that.
   > 
   > Edit: This was in response to your deleted comment. If you have another solution to write the unit test here, please feel free to use that.
   > 
   > > Sorry, I tried my best to write this unit test according to this method, but since newGauge has a return value, there is no way to use doAnswer. It seems that KafkaMetricsGroup must be changed? [@divijvaidya](https://github.com/divijvaidya)
   
   Hello, thank you for your submission, I have learned a lot, and I was not familiar with the use of mockito :)
   I have merged your commit into this final commit. @divijvaidya 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org