You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2019/08/26 22:25:00 UTC

[jira] [Commented] (KAFKA-8837) KafkaMetricReporterClusterIdTest may not shutdown ZooKeeperTestHarness

    [ https://issues.apache.org/jira/browse/KAFKA-8837?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16916175#comment-16916175 ] 

ASF GitHub Bot commented on KAFKA-8837:
---------------------------------------

anatasiavela commented on pull request #7255: KAFKA-8837: KafkaMetricReporterClusterIdTest may not shutdown ZooKeeperTestHarness
URL: https://github.com/apache/kafka/pull/7255
 
 
   Rearrange the order of executing a tearDown in KafkaMetricReporterClusterIdTest. This will ensure everything that follows the assert is executed as well.
   
   ### Committer Checklist (excluded from commit message)
   - [ ] Verify design and implementation 
   - [ ] Verify test coverage and CI build status
   - [ ] Verify documentation (including upgrade notes)
   
 
----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> KafkaMetricReporterClusterIdTest may not shutdown ZooKeeperTestHarness
> ----------------------------------------------------------------------
>
>                 Key: KAFKA-8837
>                 URL: https://issues.apache.org/jira/browse/KAFKA-8837
>             Project: Kafka
>          Issue Type: Bug
>          Components: core
>            Reporter: Anna Povzner
>            Assignee: Anastasia Vela
>            Priority: Major
>
> @After method in KafkaMetricReporterClusterIdTest calls  `TestUtils.verifyNonDaemonThreadsStatus(this.getClass.getName)` before it calls tearDown on ZooKeeperTestHarness (which shut downs ZK and zk client). If verifyNonDaemonThreadsStatus asserts, the rest of the resources will not get cleaned up.
> We should move `TestUtils.verifyNonDaemonThreadsStatus(this.getClass.getName)` to the end of `tearDown()`. However, would also be good to prevent people using this method in tear down similarly in the future. Maybe just adding a comment would help here.



--
This message was sent by Atlassian Jira
(v8.3.2#803003)