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

Anu Engineer commented on HDFS-10808:
-------------------------------------

[~eddyxu] Thanks for your comments. 

bq. Is clearExitFlag() duplicated to setRunnable()?
Yes, you are absolutely right. Thanks for catching this. I should have called 
setRunnable instead of adding a new function. I will fix that and post a new 
patch.

bq. I don't follow why it becomes no-ops. If someone else have set exitFlag, 
either way (using continue or break) here will stop the while loop, right?
Sorry my comment was cryptic. The intend of having the setExitFlag was to 
reduce the complexity of multiple exits from the loop. Yes, it is possible for 
us to set the exit from another thread, but that was not the main use case and 
we don't rely on setExitFlag from other threads. When we discuss cancel it 
would be apparent.

bq. then diskbalancer -cancel command can not actually stop BlockMover thread 
for multiple work items?
That is a very valid concern. Fortunately for us, the way we do cancel is by 
cancelling the executor and not by relying on this flag. Please look at 
{{shutdownExecutor}}


> DiskBalancer does not execute multi-steps plan-redux
> ----------------------------------------------------
>
>                 Key: HDFS-10808
>                 URL: https://issues.apache.org/jira/browse/HDFS-10808
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: balancer & mover
>            Reporter: Anu Engineer
>            Assignee: Anu Engineer
>         Attachments: HDFS-10808.001.patch
>
>
> This is to redo of the fix in HDFS-10598



--
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