How is it possible for a Hyperledger Sawtooth Validator node to have 'number of peers greater than the maximum connectivity' in the Sawtooth Network?

主宰稳场 提交于 2019-12-24 03:44:18

问题


Below statement is from this documentation.

The network component continues to perform a peer search if its number of peers is less than the minimum connectivity. The network component rejects peering attempts if its number of peers is equal to or greater than the maximum connectivity.

Question:

As the documentation says,

number of peers is equal to or greater than the maximum connectivity,

If a node is allowed to have a 'maximum number of peers', say N, how can the 'number of peers' be GREATER than N ?

NOTE:

You may want to refer to another question from me, which was related to 'maximum connection between nodes' which happens before 'attempting peering'. The main difference between these 2 questions is about 'maximum connections' and 'maximum (bi-directional) peers'.


回答1:


No, it cannot be greater than N (ideally). Looking at this code, a connection is registered as peer, if current peers is less than the maximum peers allowed. The documentation is saying it in terms of condition for rejection. ie ("less than" vs "greater than or equal to")

The documentation is correct



来源:https://stackoverflow.com/questions/57019380/how-is-it-possible-for-a-hyperledger-sawtooth-validator-node-to-have-number-of

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!