hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xiaoyu Yao (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDDS-277) PipelineStateMachine should handle closure of pipelines in SCM
Date Thu, 26 Jul 2018 15:59:00 GMT

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

Xiaoyu Yao commented on HDDS-277:
---------------------------------

[~msingh], thanks for the update. Patch v2 looks good except one minor comment. +1 after that
fixed.

PipelineSelector.java Line 339
{code}
    NavigableSet<ContainerID> containerIDS = containerStateManager
        .getMatchingContainerIDsByPipeline(pipeline.getPipelineName());
    if (pipeline.getLifeCycleState() == LifeCycleState.CLOSING &&
        containerIDS.size() == 0) {
      updatePipelineState(pipeline, HddsProtos.LifeCycleEvent.CLOSE);
      LOG.info("Closing pipeline. pipelineID: {}", pipeline.getPipelineName());
    }
{code}

Can we change it to  to avoid unnecessary getMatchingContainerIDsByPipeline call?

{code}
    if (pipeline.getLifeCycleState() != LifeCycleState.CLOSING) {
      return;
    }
    NavigableSet<ContainerID> containerIDS = containerStateManager
        .getMatchingContainerIDsByPipeline(pipeline.getPipelineName());
    if  (containerIDS.size() == 0) {
      updatePipelineState(pipeline, HddsProtos.LifeCycleEvent.CLOSE);
      LOG.info("Closing pipeline. pipelineID: {}", pipeline.getPipelineName());
    }
{code}


> PipelineStateMachine should handle closure of pipelines in SCM
> --------------------------------------------------------------
>
>                 Key: HDDS-277
>                 URL: https://issues.apache.org/jira/browse/HDDS-277
>             Project: Hadoop Distributed Data Store
>          Issue Type: Bug
>          Components: SCM
>    Affects Versions: 0.2.1
>            Reporter: Mukul Kumar Singh
>            Assignee: Mukul Kumar Singh
>            Priority: Blocker
>             Fix For: 0.2.1
>
>         Attachments: HDDS-277.001.patch, HDDS-277.002.patch, HDDS-277.003.patch
>
>
> Currently the only visible state of pipelines in SCM is the open state. This jira adds
capability to PipelineStateMachine to close a SCM pipeline and corresponding open containers
on the pipeline. Once all the containers on the pipeline have been closed then the nodes of
the pipeline will be released back to the free node pool



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org


Mime
View raw message