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

Uma Maheswara Rao G commented on HDFS-11151:
--------------------------------------------

[~rakeshr], Thank you for the patch.

{code}
+    boolean needBlockStorageMovement = false;
+    for (BlockMovingInfo blkMovingInfo : blockMovingInfos) {
+      // Check for atleast one block storage movement has been chosen
+      if (blkMovingInfo.getTargets().length > 0){
+        needBlockStorageMovement = true;
+        break;
+      }
+    }
+    if (!needBlockStorageMovement) {
+      // Simply return as there is no targets selected for scheduling the block
+      // movement.
+      return;
+    }
{code}
Here simply returning may completely drop this element?  I think we may need to 
add the item to attempted items? So, that it will be retried after some time?

> [SPS]: StoragePolicySatisfier should gracefully handle when there is no 
> target node with the required storage type
> ------------------------------------------------------------------------------------------------------------------
>
>                 Key: HDFS-11151
>                 URL: https://issues.apache.org/jira/browse/HDFS-11151
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: datanode, namenode
>            Reporter: Rakesh R
>            Assignee: Rakesh R
>         Attachments: HDFS-11151-HDFS-10285.00.patch
>
>
> Presently SPS is not handling a case where the failed to choose target node 
> for the required storage type. In general, there are two cases:
> # For the given path, unable to find any target node for any of its blocks or 
> block locations(src nodes). Means, no block movement will be scheduled 
> against this path.
> # For the given path, there are few target nodes available for few block 
> locations(source nodes). Means, some of the blocks or block locations(src 
> nodes) under the given path will be scheduled for block movement.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to