---
# System prepended metadata

title: 区块链评测工具

---

# 区块链评测工具

## 参考工具

* [caliper](https://github.com/hyperledger/caliper)
    * ![](https://i.imgur.com/eELAnOr.png)

* [tape](https://github.com/Hyperledger-TWGC/tape)
     ![](https://i.imgur.com/cY86Pfk.png)

* 信通院的trustedbench（目前还没开源）
* [BlockchainPerformanceMonitoring](https://github.com/InPlusLab/BlockchainPerformanceMonitoring) from paper *A Detailed and Real-time Performance Monitoring Framework for Blockchain Systems*
    * parses only `TPS`, `starttime`, `endtime`, `txconfirmedcount`

## 性能指标 Performance Metrics

* 交易吞吐量 throughput/TPS
* 交易确认延迟 transaction latency
* 交易成功率 transaction success rate
* 只读操作吞吐量 read only TPS
* 只读操作延迟 read-only latency
* 系统可扩展性 scalability
* 系统容错性 fault-tolerant
        *note: test if the system is still workingwhen certain nodes fail*
    * CFT (our focus)
        * kafka
        * raft
    * BFT
        * PBFT
* 资源利用率（CPU，网络，磁盘，能耗等等）
 *note: based on system functionalities/tools*
* ~~新节点启动时间~~

## 支持平台 Supported Platform

* Hyperledger Fabric (Golang)
* Ethereum (Solidity)
* R3 Corda (Java)

## scenarios of using smart contracts 分类1

1. copyright protection 文化版权
    * NFT
3. law 司法存证
    * [Fisco Bcos code](https://github.com/FISCO-BCOS/evidenceSample)
4. government services 政务服务 
    * 智慧城市建设
    * 自然资源登记
    * 政务诚信
5. IoT 物联网
    [fabric code](https://github.com/yigitpolat/Hyperledger-Fabric-for-Trusted-IoT)
    * 智能家居跨平台联盟
    * 农业溯源
5. 金融行业 trade & finance
    * 网贷机构良性退出
    * 机构间对账
        * [fabric code](https://github.com/hyperledger/fabric-samples/tree/main/interest_rate_swaps)
    * 供应链金融
        * [Fabric code](https://github.com/wearetheledger/awesome-hyperledger-fabric)
    * 旅游金融
    * 拍卖
        * [fabric code](https://github.com/hyperledger/fabric-samples/tree/main/auction-simple)
6. 智慧社区
    * 物业管理
7. 公益事业
    * 慈善 charity
        * solidity codes
            * [1](https://github.com/vbarzokas/smart-contract-donations/blob/master/contracts/Charitable.sol)
            * [2](https://github.com/wsun19/Blockchains-Project/blob/master/contracts/Charity.sol)
            * [3](https://github.com/rubyruby/charity-contracts/blob/master/Charity.sol)
        Problem found: the functionalities of the code is rather simple just transfer assets
    * 环保 climate
        * [fabric code](https://github.com/hyperledger-labs/blockchain-carbon-accounting)
9. 人才招娉
10. 游戏娱乐
    Based on [DappRadar](https://dappradar.com/rankings/category/games)


# 分类2

* 贸易
    * [Commercial Paper](https://github.com/hyperledger/fabric-samples/tree/main/commercial-paper)
        * Participants
            * **Digibank**
                * Issue
            * **Magnetcorp**
                * Buy
                * Redeem
                * Queries
* 物流
    * [Supplychain Example](https://github.com/xcottos/convector-example-supplychain-master)
        * Mutiple Parties
            + **Supplier**
                + rawMaterialAvailable: is a number that expresses the quantity of raw material available to be supplied
            + **Manufacturer**
                + rawMaterialAvailable: is a number that expresses the quantity of raw material available to be used for creating products
                + productsAvailable: is a number that expresses the quantity of products ready to be distributed
            + **Distributor**
                + productsToBeShipped: is a number that expresses the quantity of products ready to be shipped
                + productsShipped: is a number that expresses the quantity of products shipped
                + productsReceived: is a number that expresses the quantity of products shipped that have been received.
            + **Retailer**
                + productsOrdered: is a number that expresses the quantity of products ordered
                + productsAvailable: is a number that expresses the quantity of products available for being sold
                + productsSold: is a number that expresses the quantity of products that have been sold
            + **Customer**
                + productsBought: is a number that expresses the quantity of products bought
            + helper functions
                + **createSupplier**: creates a Supplier
                + **createManufacturer**: creates a Manufacturer
                + **createDistributor**: creates a Distributor
                + **createRetailer**: creates a Retailer
                + **createCustomer**: creates a Customer
                + **getAllSuppliers**: shows all the created Suppliers
                + **getAllManufacturers**: shows all the created Manufacturers
                + **getAllDistributors**: shows all the created Distributors
                + **getAllRetailers**: shows all the created Retailers
                + **getAllCustomers**: shows all the created Customers
                + **getAllModels**: shows all the created Models

* 文娱
    * [Simple Ping Pong Game](https://github.com/cnnrznn/fabric-samples/blob/release-1.4/chaincode/fabcar/javascript/lib/fabcar.js)
        * Based on fabcar example
        * The transacions per block was reduced to one to eliminate the latency of compiling a block
    * NFT
* 社会公共服务
    * [TrustID](https://github.com/hyperledger-labs/TrustID)
        * Individual Identity
            * DID
            * PublicKey
            * Controller
            * Access
        * Service Identity
            * DID
            * Name
            * Public
            * Access
            * Controller
* 金融
    * [IBM/global-financing-blockchain](https://github.com/IBM/global-financing-blockchain)
        * Based on `Order`
        * Created
        * Bought
        * Cancelled
        * Ordered
        * ShipRequest
        * Delivered
        * Delivering
        * Backordered
        * Dispute
        * Resolve
        * PayRequest
        * Authorize
        * Paid
        * Refund
        * Refunded
* 政务
    * [citizen-pulse](https://github.com/hyperledger-labs/citizens-pulse)
        * CRUD OPs
* 知识产权
    * [Intellectural Property](https://github.com/mickeymond/fabric-ipn-contract/blob/master/src/contracts/CopyrightContract.ts)
        * CRUD OPs
* 社交
    * forum content to chain (example not found on chaincode)
        * solidty
* 日常消费
    * Supply Chain Example
        * [fabric-supply-chain](https://github.com/jiaxyan/fabric-supply-chain/blob/master/example01/chaincode.go)
            * ProductName
            * Supplier
            * ArrivedTime
            * Singature
        * [Automation Framework](https://github.com/hyperledger-labs/blockchain-automation-framework/blob/master/docs/source/example/supplychain.md)
            * [chaincode](https://github.com/hyperledger-labs/blockchain-automation-framework/blob/master/examples/supplychain-app/fabric/chaincode_rest_server/chaincode/supplychain/Common.go)
            * trackingID
            * type
            * health
            * location
            * containerID
            * custodian
            * timestamp
            * contents
            * participants
* 工业
    * [Fabric-Machine](https://github.com/hyperledger-labs/fabric-machine)
* 农业
    * [Precision Farming](https://github.com/manilpuri9/hyperledger-fabric-precision-farming)
        * `GeoLocation`
        * `FarmInfo`
        * `Temperature`
        * `Pressure`
        * `Humidity`
        * `Radiation`
        * `Moisture`
        * `Nitrogen`
        * `Phosphorus`
        * `Weather`
        * `SoilCondition`
        * `Crop`
* 能源
    * [Decentralized Energy](https://github.com/IBM/decentralized-energy-fabric-on-IBP20)
        * Participants
            * **Residents**
            * **Banks**
            * **utilityCompanies**
            * **identityMap**
        * Functions
            * EnergyTrade
            * CashTrade
* 教育
    * [education](https://github.com/kevin-hf/education/blob/master/chaincode/eduCC.go)
        * 仅仅数据上链
        * simple key-value
* 医疗
    * [substra-chaincode](https://github.com/Substra/substra-chaincode)
        - `cancelComputePlan`
        - `createAggregatetuple`
        - `createCompositeTraintuple`
        - `createComputePlan`
        - `createTesttuple`
        - `createTraintuple`
        - `logFailAggregate`
        - `logFailCompositeTrain`
        - `logFailTest`
        - `logFailTrain`
        - `logStartAggregate`
        - `logStartCompositeTrain`
        - `logStartTest`
        - `logStartTrain`
        - `logSuccessAggregate`
        - `logSuccessCompositeTrain`
        - `logSuccessTest`
        - `logSuccessTrain`
        - `queryAggregateAlgo`
        - `queryAggregateAlgos`
        - `queryAggregatetuple`
        - `queryAggregatetuples`
        - `queryAlgo`
        - `queryAlgos`
        - `queryCompositeAlgo`
        - `queryCompositeAlgos`
        - `queryCompositeTraintuple`
        - `queryCompositeTraintuples`
        - `queryComputePlan`
        - `queryComputePlans`
        - `queryDataManager`
        - `queryDataManagers`
        - `queryDataSamples`
        - `queryDataset`
        - `queryFilter`
        - `queryModelDetails`
        - `queryModelPermissions`
        - `queryModels`
        - `queryNodes`
        - `queryObjective`
        - `queryObjectiveLeaderboard`
        - `queryObjectives`
        - `queryTesttuple`
        - `queryTesttuples`
        - `queryTraintuple`
        - `queryTraintuples`
        - `registerAggregateAlgo`
        - `registerAlgo`
        - `registerCompositeAlgo`
        - `registerDataManager`
        - `registerDataSample`
        - `registerNode`
        - `registerObjective`
        - `updateComputePlan`
        - `updateDataManager`
        - `updateDataSample`


| 贸易              | 物流                   | 文娱                  | 社会公共服务         | 金融                            |
|-------------------|------------------------|-----------------------|----------------------|---------------------------------|
| Commercial Paper  | Supplychain Example    | Simple Ping Pong Game | TrustID              | IBM/global-financing-blockchain |
| 政务              | 知识产权               | 社交                  | 日常消费             | 工业                            |
| citizen-pulse     | Intellectural Property | null                  | Supply Chain Example | Fabric-Machine                  |
| 农业              | 能源                   | 教育                  | 医疗                 |                                 |
| Precision Farming | Decentralized Energy   | education             | substra-chaincode    |                                 |