Multi-Chain Architecture
Last updated
Last updated
In aelf V1, we introduced a novel multichain architecture. This architecture consists of two primary components:
aelf Mainchain: This is the core blockchain that acts as the foundation for the entire network. The MainChain is mainly repsonsible for the core functionalities supporting the operation of the network such as the DPoS Consensus Protocol, Token system and side chain indexing - all are realized via system contracts. You can explore the mainchain on the aelf explorer .
Sidechains: These are independent blockchains built on top of the mainchain, each catering to specific use cases. An example of a sidechain is the tDVV sidechain, which you can explore on its dedicated explorer .
This multichain approach offers several advantages:
Resource Isolation: Sudden traffic spikes targeting specific dApps or contracts won't disrupt the operations of other dApps on separate chains. This is because contracts can be strategically deployed on different chains based on their resource needs.
Shared Governance and Tokens: All chains within the ecosystem can leverage the same governance mechanisms and utilize the same underlying tokens for transactions.
Scalable Infrastructure: The multichain architecture allows for horizontal scaling. When the network demands more processing power, additional sidechains can be added. Different smart contracts can then run on different sidechains to execute workloads in parallel.
Homogeneous Tech Stack: Developers can leverage the same development tools and ecosystem functionalities across all chains within the aelf network, fostering a more streamlined and efficient development experience. For a visual representation of the node architecture, refer to Figure 8.0 below.
You can find an overview of aelf's architecture . Node operators run the node software for all supported sidechains and the mainchain. Each chain maintains its own P2P network and block producing rules. All chains share the same set of block producers determined by token holders voting on the main chain.
depicts how a node interacts with multiple chains. Each node runs a full client for both the mainchain and all connected sidechains. These clients maintain private connections for secure communication. Block production adheres to the DPoS consensus protocol. Once a block is finalized on a chain, the corresponding client on other chains broadcasts a system transaction. This transaction proposes indexing the finalized block on its chain. Subsequently, block producers vote on the proposal. If more than two-thirds of the block producers approve, the proposal is executed, and the Merkle root and other relevant information are integrated into the chain. The core of the entire process is a system contract called the CrossChainContract which maintains the indexing states.