Re: What is the best practice in deploying chaincode over peers? #fabric-peer


Nikhil Gupta
 

Hello BigBang,

Others may have a different answer to this, but I would install the chaincode on all peers. That way you have redundancy in case of peer failure. If peer0Org1 goes down, then Peer1 can still process transactions and the network will still be up.

Nik


On Tue, Jan 18, 2022 at 2:07 AM BigBang019 <zhuxy0000@...> wrote:
Background:
In fabric, peers are responsible for endorsement, validation and commit, but  those who don't have chaincode can not be selected as endorsers. For example, I have peer0.org1 and peer1.org1 in organization Org1, and peer0.org2 and peer1.org2 in organization Org2. They all joined the channel mychannel, but only peer0.org1 and peer0.org2 have chaincode. In this case, if the the endorsement policy of a chaincode is set as default, i.e. magority endorsement, the workload of peer0.org1 and peer0.org2 is heavy because they have to endorse 100% tx.


So I wonder:
In a Fabric network, the percentage of those who have chaincode can affect the performance of the network. How much of that percentage is the best practice?

Join fabric@lists.hyperledger.org to automatically receive all group messages.