Fabric core concept

Fabric core concept

 

The hyperledger fabric meets all the characteristics of the blockchain mentioned above. We must first understand some of its concepts before we can further understand its architectural design. Since most of the information in English, these concepts are based on the English description: 

chaincode: smart contract, each chaincode can provide multiple different calling commands. 
Smart contracts are modular, reusable, and automatically executed scripts that run on the blockchain. With it, we can complete complex business logic. For example, there are multiple contracts on the same blockchain, and each contract can be agreed Different participants (enterprise or related parties). You can also specify each subcommand in each contract to do a batch of specific things. You can think of it as a transaction in a relational database.
In the fabric, the smart contract is called chaincode, and it has 6 states, as shown below
Install → Instantiate → invocable → Upgrade → Deinstantiate → Uninstall.
In fact, the smart contract is a piece of code, which is officially recognized by the GO language. First of all, we need to upload the contract code to the blockchain. The status of this step is called Install
needs to be initialized. For example, the current data is stored in mysql, so you need to use Instantiate to migrate the data to the chain when you go online, which is also considered initialization. After initialization, chaincode enters the invocable callable state.
General, we can use the SDK command line or program to call the contract with the SDK

  Because the alliance chain spans multiple enterprises, multiple regions, and even countries, it is difficult to maintain a consistent version of the contract. Therefore, each contract has a version number. When the version is upgraded, it is in the Upgrade state.
  The last two states correspond to contract off chain


transaction: transaction, each instruction is a transaction. 
world state: The final value formed by multiple transactions of the same key is the world state. 
endorse: endorsement. In financial terms, it refers to the act of the bearer in order to transfer the rights of the bill to others or to grant certain bills rights to others to exercise, and record the relevant matters on the back of the bill or stick the bill and sign. Usually we are extended to be responsible for something. In the voting link of our consensus mechanism, endorsement means participating in voting. 
endorsement policy: Endorsement policy. The smart contract chaincode selects which peer nodes participate in the endorsement. 
peer: Node for storing blockchain data, as well as endorse and commit functions. 
channel: Private subnet, in fact, to isolate different applications, a channel can contain a batch of chaincode. 
PKI: Public Key Infrastructure, a technology and specification that provides a set of secure basic platforms for the development of e-commerce following the standard using public key encryption technology. 
MSP: Membership Service Provider, certificate management of alliance chain members, which defines which RCA and ICA are trusted in the chain, including the definition of collaborators on the channel. 
org: orginazation, an organization that manages a series of cooperative enterprises.



 

 

Original link: https://blog.csdn.net/russell_tao/java/article/details/80459698

Guess you like

Origin www.cnblogs.com/fengjian2016/p/12738246.html