Reputation: 37
I am currently undergoing a project that compares a public blockchain like Ethereum and a consortium blockchain like Hyperledger Fabric.
I will be designing and implementing smart contracts on both platforms in order to measure their tx speed and cost.
Further things will be compared like privacy, potential scalability, governance and consensus protocols.
Looking to write Eth smart contracts in Solidity, and Fabric in Golang. My experience of this is extremely minimal and so I am just looking to implement basic contract contracts, execute several on both platforms and compare.
Is there a way to do dummy runs of smart contracts that simulate the real thing?
Upvotes: 0
Views: 513
Reputation: 4037
FWIW, Hyperledger Fabric now has support for running Solidity (and other EVM compliant) contracts. We have published v1.2.0-rc1 of this feature. Basically, the image (published on DockerHub here) can be used in place of a hyperledger/fabric-peer image in a local test config, such as can be found in the e2e_cli directory of the fabric-chaincode-evm repository. We are working on a Web3 proxy, but that isn't much more than a POC at present. However, you can use one of the SDKs or the CLI (as in the example referenced earlier) to submit transactions, etc.
Upvotes: 5
Reputation: 934
I don't know much about Fabric, but for Ethereum you should check out truffle. It's a tool for running ethereum smart contracts in a test environment running on you local machine, provides a full-fledged testing library and even helps you deploy smart contracts to the public blockchain.
You might also find quorum interesting. It is an open source project for running private block chains using the Ethereum protocol.
Upvotes: 0