Hadoop Map/Reduce
  1. Hadoop Map/Reduce
  2. MAPREDUCE-3622

findbug error during test-patch: org.apache.hadoop.mapreduce.v2.app.launcher.ContainerRemoteLaunchEvent defines equals but not hashCode

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 0.23.0
    • Fix Version/s: None
    • Component/s: mrv2
    • Labels:
      None

      Description

      findbug error: org.apache.hadoop.mapreduce.v2.app.launcher.ContainerRemoteLaunchEvent defines equals but not hashCode

      first time I see this is build 1540:

      https://builds.apache.org/job/PreCommit-MAPREDUCE-Build/1540//artifact/trunk/hadoop-mapreduce-project/patchprocess/newPatchFindbugsWarningshadoop-mapreduce-client-app.html

        Issue Links

          Activity

          Hide
          Robert Joseph Evans added a comment -

          Strike that last comment. I guess eclipse some how got confused and pointed me to the wrong file. My first comment still stands. As part of MAPREDUCE-3312 I will be fixing this issue because the need for the equals hack will not longer be needed. I should upload a patch to MAPREDUCE-3312 shortly.

          Show
          Robert Joseph Evans added a comment - Strike that last comment. I guess eclipse some how got confused and pointed me to the wrong file. My first comment still stands. As part of MAPREDUCE-3312 I will be fixing this issue because the need for the equals hack will not longer be needed. I should upload a patch to MAPREDUCE-3312 shortly.
          Hide
          Robert Joseph Evans added a comment -

          Sorry I guess I am wrong about that. Yes the equals method for ContainerRemoteLaunchEvent is being abused, and I am fixing that in MAPREDUCE-3312, but ContainerRemoteLaunchEvent gets its equals method from its parent ContainerRemoteLaunchEvent which has both an equals and a hashCode in both 0.23 and trunk. There must be something odd happening with Findbugs.

          Show
          Robert Joseph Evans added a comment - Sorry I guess I am wrong about that. Yes the equals method for ContainerRemoteLaunchEvent is being abused, and I am fixing that in MAPREDUCE-3312 , but ContainerRemoteLaunchEvent gets its equals method from its parent ContainerRemoteLaunchEvent which has both an equals and a hashCode in both 0.23 and trunk. There must be something odd happening with Findbugs.
          Hide
          Robert Joseph Evans added a comment -

          As part of my work for MAPREDUCE-3312 the equals method will be removed. The equals method is here as a bit of a hack so that related events in a queue can be removed without having to write code to walk the queue themselves.

          Show
          Robert Joseph Evans added a comment - As part of my work for MAPREDUCE-3312 the equals method will be removed. The equals method is here as a bit of a hack so that related events in a queue can be removed without having to write code to walk the queue themselves.

            People

            • Assignee:
              Unassigned
              Reporter:
              Thomas Graves
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development