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

Shashikant Banerjee updated HDDS-185:
-------------------------------------
    Description: 
CloseCommand gets picked up via datanode by the Hearbeat response it receives 
from SCM. It may happen, one of the follower node not yet received the 
heartBeat response from SCM whereas the leader has got issued the 
closeContainer Command encoded from its own HeartBeat response from SCM. In 
such a case, leader will close the container followed by the followers.

The follower on which the container is closed Via ratis, has not yet received 
any CloseContainer command from SCM directly and hence on that 
closeCommandHandler is not invoked yet. hence the assertion on the below code 
in one of the followers:
{code:java}
if (!containerData.isOpen()) {
  // make sure the closeContainerHandler on the Datanode is invoked
  Assert.assertTrue(
      datanodeService.getDatanodeStateMachine().getCommandDispatcher()
          .getCloseContainerHandler().getInvocationCount() > 0);
  return true;
}{code}
 

  was:
CloseCommand gets picked up via datanode by the Hearbeat response it receives 
from SCM. It may happen, one of the follower node not yet received the 
heartBeat response from SCM whereas the leader has got issued the 
closeContainer Command encoded from its own HeartBeat response from SCM. In 
such a case, leader will close the container followed by the followers.

The follower on which the container is closed Via ratis, has not yet received 
any CloseContainer command from SCM directly and hence on that 
closeCommandHandler will never be invoked. hence the assertion on the below 
code in one of the followers:
{code:java}
if (!containerData.isOpen()) {
  // make sure the closeContainerHandler on the Datanode is invoked
  Assert.assertTrue(
      datanodeService.getDatanodeStateMachine().getCommandDispatcher()
          .getCloseContainerHandler().getInvocationCount() > 0);
  return true;
}{code}
 


> TestCloseContainerByPipeline#testCloseContainerViaRatis fail intermittently
> ---------------------------------------------------------------------------
>
>                 Key: HDDS-185
>                 URL: https://issues.apache.org/jira/browse/HDDS-185
>             Project: Hadoop Distributed Data Store
>          Issue Type: Sub-task
>          Components: SCM
>            Reporter: Shashikant Banerjee
>            Assignee: Shashikant Banerjee
>            Priority: Major
>
> CloseCommand gets picked up via datanode by the Hearbeat response it receives 
> from SCM. It may happen, one of the follower node not yet received the 
> heartBeat response from SCM whereas the leader has got issued the 
> closeContainer Command encoded from its own HeartBeat response from SCM. In 
> such a case, leader will close the container followed by the followers.
> The follower on which the container is closed Via ratis, has not yet received 
> any CloseContainer command from SCM directly and hence on that 
> closeCommandHandler is not invoked yet. hence the assertion on the below code 
> in one of the followers:
> {code:java}
> if (!containerData.isOpen()) {
>   // make sure the closeContainerHandler on the Datanode is invoked
>   Assert.assertTrue(
>       datanodeService.getDatanodeStateMachine().getCommandDispatcher()
>           .getCloseContainerHandler().getInvocationCount() > 0);
>   return true;
> }{code}
>  



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

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

Reply via email to