Just like a Blockchain a Hashgraph is a Datastructure working with a decentralized protocole. The Hashgraph has been developed by Leemon Baird in mid 2016 and is the intellectual property of Swirlds company founded by Leemon.
The following description puts in perspective the Hashgraph and blockchains like Bitcoin or Ethereum to get a better sens of the strengths and weaknesses of both technologies.
- Data storage :
In the Blockchain, data is stored in blocks which contains :
All the transactions made in a given period of time, a timestamp, the hash of the block and the hash of the previous block.
In the Hashgraph data is stored in events which contains :
A timestamp and transactions just like a block and two regular hashes.
2. Data structure :
While in blockchains a consensus protocole is ran to select one node which will have the right to add a block of transactions to the distributed chain of blocks, in the Hashgraph all the nodes of the network communicate the latest state of their information to each other and their communication are recorded building a graph of connections.
3. Protocole :
a) Common ground : the gossip protocole
The gossip protocole is used in the blockchain and in the Hashgraph to spread the informations through the network. Basically each time a node is sent a new transaction it communicates it to its neighbours nodes and so on.
b) Consensus protocole
In this section we will describe the Proof of work consensus protocole which is used by the most famous blockchains as Bitcoin and Ethereum. The nodes are competing on a very complex mathematical challenge to gain the right to add their data to the blockchain. It takes on average 10 min to validate a block and consume a ridiculous amount of energy equivalent to the electricity required to power 8.61 US household for 1 day. In the Bitcoin and Ethereum protocole nodes have to run a safety algorithm which verifies all transactions to make sure they do not accept a malicious transaction. Although if the node try to fraud and add a block with a double spend transaction for instance, the next node to add a block to the blockchain will reject it, connect with the node before it and so the transactions of the fraud block will be deleted. The cost of mining is supposed to dissuade miners to try these kinds of attacks on a blockchain however if several nodes are dishonest the “fraud chain” can gain in length. This means that in the Proof of work consensus the consensus is actually never reached but only approached which also explain why a receiver of a transaction usually wait for the confirmation of several nodes to validate a transaction.
The Hashgraph breakthrough is nested in the validation protocole. The hasgraph consensus protocole is based on the connection graph we described earlier and does not require any additional effort from the network nodes. The process is the following :
STEP 0: The Hashgraph is divided in rounds. One round is created each time one event is able to connect more than 2/3 of the firsts events of the current round by more paths than 2/3 of the node population.
By doing so one event « strongly sees » another event.
In the example B4 strongly sees A3. (Node population = 4, number of connecting path = 3)
STEP 2 : Each time a new round is created the first new nodes of the new round will vote to say if they would agreed upon the data contained in the first row of events of the preceding round. To do so they just need to verify that they are connected to these nodes.
In this example all the 3rd round first nodes would have agreed upon the data in A2
STEP : 3 The last stage is to collect the 3rd round nodes answers. To do so the 4th round nodes are required. They need to strongly see the 3rd round node (cf example). If one of the 4th round node succeed to collect a super majority (more than 2/3 of the population) of positive votes (STEP 2) upon the data in the 2nd round then the consensus is found this data.
For more details on the Hashgraph consensus process, please visit : https://hashgraph.com/
Transactions per second (tps) : Bitcoin and Ethereum are limited by their consensus protocole to respectively 7 and 15 tps whereas Hasgraph is only limited by the bandwith of the internet to 250k tps which is 5 times superior to the visa network.
Security : Hashgraph is the unique distributed consensus technology which is A-BFT (Asynchronous Byzantine Fault Tolerance). This means that with the only assumption that less than 1/3 of the nodes are malicious the protocole will always find a consensus and it will always be the right one. It is mathematically proven that 1/3 of the nodes is the uncompressible limit for a system to be BFT. Moreover the Hashgraph is the only Decentralized protocole which is “bank grade security level” and can work with financial institutions.
Fairness : In Blockchain a node choose to add a transaction or not in a block and the order in which it wants the transaction to be ordered. This can be perceived as unfair by the end-users and prevents to build applications such as stock exchange on a blockchain. In Hashgraph the timestamp protocole is totally fair for all the users (details here).
Scalability : The SDK is in Java which is more commonly mastered than solidity.
Today there is no public distributed ledger — What will happen when the verification scrypt will have to run at every gossip?
The adoption process for a distributed ledger seems to be challenging. In Bitcoin or Ethereum nodes are incentivized not to cheat as the proof of work is expensive and their potential profits will hardly met their losses. In Hasgraph there are no incentives of this kind and it would be more interesting for malicious nodes to try to fraud on Hashgraph than on other blockchains.
In the Hashgraph protocol each node has to store the totality of the hashgraph — How restrictive would that be?
By design no fork is possible — is this a good thing?
- In September 2017 Swirlds raised 3M USD in seeds with NEA venture capital.
- In October 2017 Swirlds sell a license for the usage of their hasghraph technology to Credit Union
- Telegram : 4360 members
- Twitter : 2672 membership
- Youtube : 1080 views
- Techcrunch disrupt hackathon