Friday, July 28, 2017

AbstractStreamSession convict stream error

Today we will take a look at the following error in apache cassandra 1.2.19

 ERROR [GossipStage:1] 2016-09-21 19:38:54,486 (line 108) Stream failed because / died or was restarted/removed (streams may still be active in background, but further streams won't be started)  

I was not sure how serious is this but I've taken a look into this class to further determine the degree of seriousness of this error. Let's jump right into the class AbstractStreamSession.

  • it is an abstract class 
  • subclass of StreamInSession and StreamOutSession
  • when close(boolean) method is called, gossiper unregistered, and failure detector is also unregistered. 
In the method convict(InetAddress, double), snippet below:

   public void convict(InetAddress endpoint, double phi)  
     if (!endpoint.equals(getHost()))  
     // We want a higher confidence in the failure detection than usual because failing a streaming wrongly has a high cost.  
     if (phi < 100 * DatabaseDescriptor.getPhiConvictThreshold())  
     logger.error("Stream failed because {} died or was restarted/removed (streams may still be active "  
            + "in background, but further streams won't be started)", endpoint);  

We see that the phi value is greater than 100 * DatabaseDescriptor.getPhiConvictThreshold() and thus, this is consider an error for the endpoint and a further close method with success as a false is called.

Guess this is not a serious problem as the close method is called and if the session is persist, a restart of cassandra should be sufficient to restream a new session.

No comments:

Post a Comment