You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ratis.apache.org by GitBox <gi...@apache.org> on 2020/11/10 01:19:17 UTC

[GitHub] [incubator-ratis] amaliujia edited a comment on pull request #264: RATIS-1140. Add primary peer id to Raft proto and only create channels with peer for primary servers

amaliujia edited a comment on pull request #264:
URL: https://github.com/apache/incubator-ratis/pull/264#issuecomment-724386492


   > > there will be a deadlock case that a server will receive a request, and then route to other peers, and other peers will do the same
   > 
   > Could you explain the deadlock clearer ? which lock was held and which lock was waited?
   
   For a normal cluster, every server can be a primary server
   
   ```
   A ----B
   \    /
   \   /
     C
   ```
   
   In previous implementation, if A receives a header request, it will forward to B and C. And then B and C will also forward the request to A and C ( A and B). So in this case, A will wait its peers to reply on the header request, same for B and C. Because each peer will wait for other to reply, I will call this is a "deadlock" situation. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org