[
https://issues.apache.org/jira/browse/YARN-4386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15049334#comment-15049334
]
Kuhu Shukla commented on YARN-4386:
-----------------------------------
I agree about the transitions being safe. We can try this test just to be super
sure although the code in {{deactivateNode}} which is called every time there
is a transition to DECOMMISSIONED state the first time, shows that such nodes
are removed from active list and put in Inactive list.
{code}
rmNode.context.getRMNodes().remove(rmNode.nodeId);
LOG.info("Deactivating Node " + rmNode.nodeId + " as it is now "
+ finalState);
rmNode.context.getInactiveRMNodes().put(rmNode.nodeId, rmNode);
{code}
Will give this test a shot nonetheless and get back.
> refreshNodesGracefully() looks at active RMNode list for recommissioning
> decommissioned nodes
> ---------------------------------------------------------------------------------------------
>
> Key: YARN-4386
> URL: https://issues.apache.org/jira/browse/YARN-4386
> Project: Hadoop YARN
> Issue Type: Bug
> Components: graceful
> Affects Versions: 3.0.0
> Reporter: Kuhu Shukla
> Assignee: Kuhu Shukla
> Priority: Minor
> Attachments: YARN-4386-v1.patch
>
>
> In refreshNodesGracefully(), during recommissioning, the entryset from
> getRMNodes() which has only active nodes (RUNNING, DECOMMISSIONING etc.) is
> used for checking 'decommissioned' nodes which are present in
> getInactiveRMNodes() map alone.
> {code}
> for (Entry<NodeId, RMNode> entry:rmContext.getRMNodes().entrySet()) {
> .........................
> // Recommissioning the nodes
> if (entry.getValue().getState() == NodeState.DECOMMISSIONING
> || entry.getValue().getState() == NodeState.DECOMMISSIONED) {
> this.rmContext.getDispatcher().getEventHandler()
> .handle(new RMNodeEvent(nodeId, RMNodeEventType.RECOMMISSION));
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)