You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mapreduce-dev@hadoop.apache.org by "Oleksandr Shevchenko (JIRA)" <ji...@apache.org> on 2018/09/10 11:47:00 UTC

[jira] [Created] (MAPREDUCE-7136) TestMRAppMetrics should shutdown DefaultMetricsSystem after completion

Oleksandr Shevchenko created MAPREDUCE-7136:
-----------------------------------------------

             Summary: TestMRAppMetrics should shutdown DefaultMetricsSystem after completion
                 Key: MAPREDUCE-7136
                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-7136
             Project: Hadoop Map/Reduce
          Issue Type: Bug
          Components: test
            Reporter: Oleksandr Shevchenko
         Attachments: image-2018-09-10-14-39-57-992.png

TestMRAppMetrics should invoke shutdown method in DefaultMetricsSystem after completion. Since it can lead to failing other tests. For example, TestRMContainerAllocator#testReportedAppProgress fails when run after TestMRAppMetrics#testNames with the following error:

{noformat}
org.apache.hadoop.metrics2.MetricsException: Metrics source MRAppMetrics already exists!
{noformat}

!image-2018-09-10-14-39-57-992.png!

We do not catch this on the trunk since the test TestRMContainerAllocator#testUnsupportedMapContainerRequirement run first and "DefaultMetricsSystem.shutdown();" invokes after completion. But since JUnit does not guarantee the order of the tests we should fix it. 
Also, this is affected by previous versions which run testReportedAppProgress first (I faced it on 2.7.0 version).



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: mapreduce-dev-unsubscribe@hadoop.apache.org
For additional commands, e-mail: mapreduce-dev-help@hadoop.apache.org