Blepcoin

Home RSS

Elrond
Public Blockchain using Adaptive State Sharding and SPoS

https://elrond.com/
lead image

Elrond is a blockchain and decentralized application platform that aims for more than 10k transactions per second, minimal latency, negligible fees, and interoperability. Elrond implements adaptive state sharding, which allows the network to scale linearly - the more validators, the more throughput and data it can support.

The consensus group is secured by “Secure Proof of Stake” and random selection using BLS single signature, where the current leader signs the previous random source with its own private key to generate a new random number. It assumes that 2/3+1 of the eligible nodes are honest (similar to many other blockchains).

On 29 May 2019, Elrond released its testnet at http://testnet.elrond.com along with a blog post detailing the update.

*Update 22 June 2019: Since this article was published, Elrond has fully opened the source of their code.*

Token metrics

The token metrics look great in this market, in my opinion. Having a larger IEO than private round means there’s less centralized sell pressure. The hardcap, at $5.15MM, is sustainable by this current market. The inflation and deflation models make sense.

From https://elrond.com/files/Elrond_Token_Metrics_EN.pdf:

Total Tokens (Genesis): 20,000,000,000 ERD, plus <2.5% inflation, minus transaction fees (burned) Softcap: $1,900.000 Hardcap: $5,150,000 Total Tokens Sold: 8,800,000,000 Percentage Sold (Private + IEO): 44.00%

Token distribution and lockups:

  • Token Generation Event (TGE) will take place during or immediately after the IEO
  • Private Round: 19.00%
    • 7.5% at TGE
    • 6 equal tranches every 3 months after IEO (15.41% every 3 months)
  • Initial Exchange Offering (IEO): 25.00%
    • 100% at TGE
  • Ecosystem Rewards: 7.00% - These tokens will be used only for incentivizing users to join the platform and/or use future products and services.
    • 50% at TGE
    • 50% 6 months after TGE
  • Marketing/Grants/Accelerator Pool: 8.50% - These funds will be distributed to individuals, developers, companies or startups willing to build and/or promote interesting tools, services or dApps on top of Elrond.
    • 81,17% at the TGE, 9,41% every 6 months after TGE
  • Community fund: 2.00% - These funds will be distributed in accordance with the decisions made by the community through the governance system.
    • 33.3% at TGE
    • 33.3% 6 months after TGE
    • 33.3% 12 months after TGE
  • Advisors: 2.50%
    • 100% 1 year after TGE
  • Team (Founders and Core team members): 19.00%
    • 10% 6 months after TGE
    • 10% 12 months after TGE
    • 15% 18, 24, 30 and 36 months after TGE
    • 20% 42 months after TGE
  • Company reserve: 17.00% - These tokens are retained by Elrond to support the Elrond network and ecosystem.
    • 33.3% at TGE - !Can only be used for staking during 1 year after TGE.!
    • 66.6% in 3 equal tranches over 3 years, starting 1 year after TGE

Market opportunity/Competitive analysis

Zilliqa, Algorand, Ethereum 2.0 (Serenity), and Multivac are competitors. While there are many technical details on how each implementation is different, and compete on throughput, scalability, and security, ultimately what they’re competing on is providing a platform that offers an easy way for developers to build reliable products.

Ethereum 1.0 is the clear winner in this regard so far, giving it the advantage of network effects; however, there is a huge unaddressed market of potential products that require higher throughput and scalability, with lower costs to use. None of the current solutions have achieved the levels of adoption that would prevent Elrond from getting there first.

Team/Advisors/Partnerships

  • Beniamin Mincu, CEO

    • Previously part of NEM core team, leading business, marketing and community efforts
    • Invested and supported some 30 blockchain projects among which Icon, Matrix and Zilliqa.
    • General Partner of Metachain Capital
    • 4 years with blockchain startups

    In other words, Beniamin knows how the industry works.

  • Lucian Todea, COO

    • Entrepreneur and active investor in startups and the blockchain space
    • 15 years experience in tech businesses, and as an executive with significant operational, business development, general management, leadership and international experience
    • CEO, founder and partner in several tech companies
  • Lucian Mincu, CIO

    • 8 years experience spanning from developing end-to-end startup products, to designing and implementing highly technical yet comprehensive infrastructure and network solutions for large enterprise clients like the German State
    • Co-founded Metachain Capital and ICO Market Data.
    • 3 years of blockchain experience.
  • Felix Crisan, Head of research

    • Co-founded BTKO, Romania’s first Bitcoin exchange platform
    • Co-founder and CTO of Netopia where he implemented market leading solutions for online and mobile payments
    • 20 years of working experience in IT and teaches BigData concepts and technologies
    • Bitcoin Lightning Network contributor
  • Radu Chis, Head of technology

    • PhD in Computer Science, research in Advanced Computer Architecture, Design Space Exploration and Machine Learning
    • Published several scientific papers in prestigious journals and international conferences
    • Participated in EU funded research projects
    • 10 years experience as a software engineer, deploying enterprise solutions for multiple sectors
  • Adrian Dobrita, Head of engineering

    • 1st Place in a national Ai Multi-Agent Systems Competition
    • BS in Computer Science, MS in Advanced Computing Systems
    • 10+ years experience in software engineering
    • Intel, ST-Ericsson, Continental, developing industry-grade embedded software in areas such as mobile and automotive. He has also worked for several startups as back-end developer
  • Iulian Pascalau, Core developer

    • 10 years experience in industrial-grade software
    • Experience with IoT devices, network infrastructures, as well as analog and digital electronics
    • Linkedin, Twitter.
    • BS in Computer Science
  • Sebastian Marian, Core developer

    • four times winner of the 3rd place in global AI competition RoboCup
    • Member of the RoboCup Executive Committee, and previously member of the RoboCup Technical Committee
    • Extensive experience in Multi-Agent Systems, Machine Learning and AI
    • 18 years experience in software engineering
    • BS in Computer Science

Other engineers: Mihai Dorian Stancu, Corcoveanu Cristian, Andrei Marinica, Robert Sasu, Camil Ioan Bancioiu, Endre Simo, Beniamin Drasovean

Other team members: Dan Voicu, Daniel Serb, Larisa Oltean

Advisors

The advising team includes an Ethereum core dev, a computer science professor, cofounders of City of Zion and NEX, and a VP of engineering.

Alex Iskold, Alex Tabarrok, Raul Jordan, Grigore Rosu, Fabio C. Canesin, Ethan Fast, Andrei Pitis.

Partnerships

Competitive Advantage

Elrond has been self-funded so far, and is fundraising after already demonstrating a proof of concept and another iteration. There are some technical/economic competitive advantages, such as low computational requirement and low network participation costs, which also help in terms of potential adoption.

In my conversations with the team, they clearly understood that competitive advantage isn’t just about the tech, but also about navigating the crypto ecosystem, gaining niche then mainstream adoption, and building a constructive development community.

Tokenomics and Token Utility

Elrond token, ERD, is a utility token that will be used as: -a unit of payment and settlement between participants in the Elrond Network -a unit of staking to validate transactions by masternodes

Tech

Regarding sharding

Sharding is a way to horizontally distribute storage and processing loads, to increase performance with scalability. Elrond accomplishes this with a method dubbed “adaptive state sharding.”

Sharding implementations have to deal with a variety of issues stemming from the complexity. The Elrond whitepaper puts it succinctly:

Sharding introduces some new challenges like: singleshard takeover attack, cross-shard communication, data availability and the need of an abstraction layer that hides the shards

- Elrond whitepaper page 5

To address these, Elrond uses a tree structure, where the shards from the last tree level also must hold the state from their siblings. This improves performance when sibling shards merge, since they already have the data.

In addition, for each epoch, a third of the nodes are uniformly redistributed across shards, thus preventing cartels from dominating a single shard.

I think that makes a lot of sense.


Secure Proof of Stake

This Proof of Stake designed by Elrond uses several layers of security schemes to prevent double spend, shard takeover, invalid transaction attacks, while keeping the whole system closely synchronized.

Layers

  1. Random sampling of nodes into shards at the end of each epoch. Minimum nodes per shard are 400, and new shards are created if the minimum requirement is met.
  2. Random sampling of nodes to form the consensus group of 63. A modified BFT scheme is used, and 2/3 + 1 valid signatures are necessary to push a new block into the blockchain. For the metachain, the consensus group size is 400.
  3. Random number generator using BLS single signature scheme. The current leader signs the previous random seed with its own private-key, effectively creating effectively a random number. The team wrote a blog post about the RNG updates since the whitepaper was written.
  4. Block-finality concept. The block with nonce N is considered final only if block with nonce N+1, …, N+k are valid and constructed on top of block N in the correct order. “Honest” validators will not build over an invalid block.
  5. Fisherman challenge. Any “node” can challenge a proposed block. The cost of an invalid challenge is the full fisherman stake. A validated challenge will result in slashing the signers of the invalid block, while the slashed amount will be rewarded to the fisherman. Challenge is done through merkle proofs.
  6. Fisherman challenge can be sent by sibling shard nodes as well, only one node from 800 has to be honest, and putting an invalid block can be challenged.
  7. Metachain only notarizes blocks from shards which are final - block finality K. In that time the fisherman can send their challenges.
  8. Data must be shared with fisherman, otherwise it does not get finalized.

The probability of signing two consecutive malicious blocks is ~10^-18 without the fisherman challenge.

Shard takeover is possible only if the malicious group has super majority. The probability of this in case of 10 shards and 25% of total nodes malicious is 2.88*10^-78 without the fisherman challenge.

SPoS is provably secure even if the malicious group is highly adaptable, and bribing was considered as well.

Probability of shard takeover with fisherman challenge is: 10^-211.

Team member Robert Sasu wrote an in-depth explanation and justification here.


Metachain

Elrond includes a metachain to notarize all network and global data operations, such as nodes joining/leaving the network, eligible validator lists computation, shard-specific consensus, handling valid/invalid transactions, etc. Every round of every epoch, each shard sends headers and proofs to this metachain, on which consensus is run. Then, shards may request information from the metachain to process cross-shard transactions.


Pruning

At the end of epoch e+1, nodes drop the body of the previous epoch’s state block (containing the hash of the Merkle tree’s root), and all blocks preceding it. Therefore, new nodes do not need to download full history; they can start from the last valid state block.


Code

The team wrote a prototype in Java, tested it, and determined that they needed to rewrite it using a faster language. I love this pragmatic approach – proofs and whitepapers only get you so far, but building and testing and iterating is a sign of experience. I saw test files for every significant component of Elrond!

Elrond-go-sandbox: the protocol

The following picture is of the recent pull request history (proposed and approved changes). Their iterative process is very clear as every issue and every pull request is linked to a Jira ticket.

Consistent progress from core team members since Summer 2018.

seednode

The seednode is a service for network discovery, and is an entry point in the network for the other nodes.

Looking at at /cmd/seednode/main.go: it creates a new random number, then creates a net messenger which does some p2p discovery using dht or mdns.

node:

There are 5 main entry points: Consensus, Data, Node, Process, and P2P.

Consensus: defines the SPOS - reducing the necessary communication rounds from 5 to 2, and communication overhead from O(N^2) to O(N). The team has implemented Bellare-Neven consensus operation and chronology with rounds and epochs already; however, the team says this will be changed to BLS multi-sig in the next few weeks.

Update 07 June 2019: BLS multi-sig is already implemented and live in the testnet.

Data: defines basic types, data structures which are needed for processing: block, header, metablock, transaction, etc. It also holds the merkle tree implementation to hold the state of the blockchain and account. Unfortunately this is something I’m unable to test, but according to the team, Elrond has a new implementation of patricia merkle trees which is 40% faster than the trie in Ethereum and faster than any other implementation in wide use in the crypto space..

Node: connecting high level components to each other.

Process: sync, bootstrap, creating new blocks, processing signed blocks, validating blocks, processing transactions, processing cross shard transactions.

Transaction sharding can be seen in process/block - here you see the core block processing units for shard and metachain as well.

P2P: builds upon libp2p and holds implementation for the communication layer: discovery through kademlia dht and mdns, and a messenger implementation that defines the communication between elrond nodes. Elrond is using pubsub for broadcasting through topics but can also send messages directly. It also has a load balancer that ensures that critical communication channels are not starved when there is high communication activity (ie. lots of transactions).

Aside from these entry points, there is another key directory:

sharding: Holds a multishard coordinator, which handles the state data according to the binary tree model described in the whitepaper. The nodes shard coordinator is currently in progress, and utilizes a fixed number of shards rather than calculated dynamically. The selection of validators for consensus groups is done in each shard according to the randomness as described in the paper, but is currently part of the consensus code. The team says it will be refactored soon into the nodes sharding coordinator.

Other directories include Crypto (cryptographic functions), DataRetreiver (key-value data holder), and Storage (a bloom filter and key-value store persistence layer).

k-framework

K is a rewrite-based executable semantic framework in which programming languages, type systems and formal analysis tools can be defined using configurations, computations and rules.

- www.kframework.org

Grigore Rosu, one of Elrond’s technical advisors, started K framework in 2003 at UIUC.

Elrond added a Golang backend K framework, which is used to create a virtual machine for smart contracts.

Check out this small subset of publications that have included K framework:

In a fruitful collaboration with Prof. Grigore Rosu’s Formal Systems Laboratory (FSL) at UIUC, Runtime Verification (RV) has used the K framework to successfully build and test a mathematical model of the Ethereum Virtual Machine, which makes it possible to formally verify the accuracy of smart contracts.

- https://runtimeverification.com/blog/k-framework-enables-verification-of-evm/

elrond-node-prototype, elrond-wallet-prototype

These are the prototypes done in Java. They haven’t been updated since Nov 2018, but gave the reason for the team to rebuild in Golang.

elrond-wallet

The Elrond client is made from Reactjs (Electron) and javascript. Works standalone and in browser.

Conclusion

Overall, I really like Elrond. My first call with them showed me that they had a great depth of knowledge not just about blockchain tech, but also so many other things: on how to manage a growing team, the importance of the non-tech side of startups, and even the intricacies of the quickly changing crypto industry.

After looking at the public and private code, along with their project management system, I can confidently say that the team knows what they’re doing. The level of detail, planning, and testing demonstrate a lot of experience handling large projects with large teams with the end of goal of creating something new and useful.

Other Info

  • using existing libraries instead of building own, unless a custom version can bring 30% performance gains
  • There is 80-85% test coverage

  • uses Jira and Continuous Integration on github

  • There’s a 30x performance improvement from prototype to testnet

Lucian Mincu, [May 1, 2019 at 11:00:38 AM]: the key management and flag configuration for starting ./node has been changed as well, this was only for testing purposes not for production.

ok

Lucian Mincu, [May 1, 2019 at 11:01:19 AM]: so everything is right now in place and we’ll have a key management system integrated before the testnet release