hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Owen O'Malley (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-4879) TestJobTrackerRestart fails on trunk
Date Wed, 17 Dec 2008 05:28:44 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-4879?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12657292#action_12657292
] 

Owen O'Malley commented on HADOOP-4879:
---------------------------------------

That is not a particularly compelling reason, because it applies to all mutable Java types.
If you use IntWritables in a hashMap as keys, you are required to not change them. Same with
HashSets. If the intent was just to support testing code, they should have been written in
the test classes as static methods. Having non-standard equals functions is problematic and
can easily lead to bugs. Arguably, we should separate out the name part of the counters so
that they can be reused between counters, which would require a lot less memory to store.
But that would be a separate issue.

> TestJobTrackerRestart fails on trunk
> ------------------------------------
>
>                 Key: HADOOP-4879
>                 URL: https://issues.apache.org/jira/browse/HADOOP-4879
>             Project: Hadoop Core
>          Issue Type: Bug
>          Components: mapred, test
>    Affects Versions: 0.20.0
>            Reporter: Arun C Murthy
>            Assignee: Owen O'Malley
>            Priority: Blocker
>             Fix For: 0.20.0
>
>         Attachments: h4879.patch, h4879.patch, HADOOP-4879-v1.patch
>
>
> HADOOP-1230 changed the definition of TaskReport.equals:
> {noformat}
> @@ -172,7 +172,7 @@
>        return false;
>      if(o.getClass().equals(TaskReport.class)) {
>        TaskReport report = (TaskReport) o;
> -      return counters.contentEquals(report.getCounters())
> +      return counters.equals(report.getCounters())
> {noformat}
> This results in:
> {noformat}
> Testcase: testJobTrackerRestart took 473.926 sec
>   FAILED
> Task reports for same attempt has changed
> junit.framework.AssertionFailedError: Task reports for same attempt has changed
>   at org.apache.hadoop.mapred.TestJobTrackerRestart.testTaskReports(TestJobTrackerRestart.java:514)
>   at org.apache.hadoop.mapred.TestJobTrackerRestart.testTaskEventsAndReportsWithRecovery(TestJobTrackerRestart.java:447)
>   at org.apache.hadoop.mapred.TestJobTrackerRestart.testJobTrackerRestart(TestJobTrackerRestart.java:599)
> {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message