[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-30 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Attachment: hdfs-3837.txt

No problem, can always do cleanup in another change. Updated patch just does 
adds an exclude.

Thanks for the reviews Suresh.

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
  Components: data-node
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt, hdfs-3837.txt, hdfs-3837.txt, 
 hdfs-3837.txt, hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-30 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

  Resolution: Fixed
   Fix Version/s: 2.2.0-alpha
Target Version/s:   (was: 2.2.0-alpha)
  Status: Resolved  (was: Patch Available)

I've committed this and merged to branch-2.

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
  Components: data-node
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Fix For: 2.2.0-alpha

 Attachments: hdfs-3837.txt, hdfs-3837.txt, hdfs-3837.txt, 
 hdfs-3837.txt, hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-28 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Attachment: hdfs-3837.txt

The findbugs warning seems bogus - This method calls equals(Object) on two 
references of different class types with no common subclasses. Therefore, the 
objects being compared are unlikely to be members of the same class at 
runtime.  Both DatanodeInfo and DatanodeRegistration extend DatanodeID so they 
 both share the equals implementation.

Anyway, I'll put the relevant code back (cast the array) since this fixes the 
findbugs warning is is fine (just more verbose).

{code}
-DatanodeID[] datanodeids = rBlock.getLocations();
+DatanodeInfo[] targets = rBlock.getLocations();
+DatanodeID[] datanodeids = (DatanodeID[])targets;
{code}

Updated patch, includes the comments as well so it's clear both classes are 
using the same equals method.

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
  Components: data-node
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt, hdfs-3837.txt, hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-28 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Attachment: hdfs-3837.txt

Updated patch attached.

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
  Components: data-node
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt, hdfs-3837.txt, hdfs-3837.txt, 
 hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-22 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Status: Patch Available  (was: Open)

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-22 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Attachment: hdfs-3837.txt

Patch attached. Rather than cast bpReg to DatanodeID let's just the methods 
DatanodeRegistration overrides from DatanodeID (but just calls the parent 
method anyway).

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Updated] (HDFS-3837) Fix DataNode.recoverBlock findbugs warning

2012-08-22 Thread Eli Collins (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-3837?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eli Collins updated HDFS-3837:
--

Status: Open  (was: Patch Available)

Thanks Suresh.  Arg, accidentally committed before test patch came back. I'll 
keep an eye on the subsequent run.

 Fix DataNode.recoverBlock findbugs warning
 --

 Key: HDFS-3837
 URL: https://issues.apache.org/jira/browse/HDFS-3837
 Project: Hadoop HDFS
  Issue Type: Bug
Affects Versions: 2.0.0-alpha
Reporter: Eli Collins
Assignee: Eli Collins
 Attachments: hdfs-3837.txt


 HDFS-2686 introduced the following findbugs warning:
 {noformat}
 Call to equals() comparing different types in 
 org.apache.hadoop.hdfs.server.datanode.DataNode.recoverBlock(BlockRecoveryCommand$RecoveringBlock)
 {noformat}
 Both are using DatanodeID#equals but it's a different method because 
 DNR#equals overrides equals for some reason (doesn't change behavior).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira