Original Author: Aragon
Original Author: Aragon
The first article in this series - What is composability? - Makes Web3 sound like a clear sky, but zoom in, mid-2020, Ethereum fee hikes are causing trouble for the Web3 Lego thesis, making every L1 project (especially something like a DAO with complex smart contracts) projects) must face the prospect of multi-chain and cross-chain expansion.
image description
Composability is not the same as scalability in theory, but is only sustainable if transaction costs are kept low, otherwise increased activity on the network leads to diminishing returns as fees erode the value of the principal. This is what happened on Ethereum: Aave-flash-loan-to-short-on-Kwenta-powered-by-inverse-instruments-on-Synthetix arbitrage transactions, gas fees, although theoretically still possible in a single atom It will be eye-popping. Because of this, many projects have been shut down or launched on different chains: the technical Babel incident made Web3 use many different languages, and destroyed the scarce security and liquidity resources.
image description
I was told there would be facial melting
side chain
side chain
side chain
side chain
The emergence of L2 solutions has been less disruptive to the Ethereum ecosystem than expected because many of these networks are compatible with Ethereums runtime engine - the Ethereum Virtual Machine (EVM), although they operate independently using their own consensus mechanisms , and can operate as a sidechain via a two-way bridge between itself and the Ethereum mainnet. Solidity - Ethereums smart contract language - compiles directly to EVM bytecode, so by replicating EVM compatibility, chains like Harmony and Polygon enable developers to redeploy their dApps without having to refactor their code too radically. This enables non-fungible token (NFT) casting, voting, and other large-scale transaction events to happen at a lower cost without affecting the Ethereum mainnet. Since deploying on Polygon and Harmony, the cost of launching a DAO on Aragon has dropped 5000x and resulted in a 5x increase in the number of DAOs created to date.
Create your DAOs
bridging
bridging
bridging
bridging
By design, blockchains and other distributed ledgers have very strict trust boundaries, meaning they cannot recognize data or commands from other chains. In order to have any kind of cross-chain interaction or to build a dApp that can lend $ETH and earn interest on Avalanches native $AVAX, it is necessary to use a third-party oracle network to independently verify the state of a chain and have access to its native commands against Another performs the operation. Because of this limitation, the most common way to transfer value between Ethereum and sidechains is to bridge using a burn and mint technique: assets on one chain are locked in a smart contract, verified by a third-party oracle, and then minted For wrapping assets on another chain. The bridge can be reversed at any time by destroying the wrapped asset, which will again be verified by the oracle to unlock the smart contract.
At no point will assets be transferred from one chain to another, but since wrapped assets are fully backed derivatives, they should always be at price parity with their reserve assets. However, Vitalik Buterin highlighted the risk that if L1 were to be 51% attacked and rolled back to a point before the bridge asset was locked, then the packaged asset on L2 - now without any backing - would be worthless Value, or greatly discounted. Note that this risk only applies to encapsulated assets, not assets issued natively on L2.
Most protocols have their own canonical bridges (approved and promoted by the core team), however, since they are not licensed, there is nothing preventing multiple bridges from being built concurrently on the same protocol. Unless coordinated among bridge developers, this could result in multiple contracts being created on L2 to represent the same L1 asset, effectively hard forking them from each other.
The most popular bridge from sidechains to Ethereum and its TVL. Source: Dune Analytics, DefiLlama. Corrected as of January 12, 2022.
The most popular bridges between sidechains and Ethereum and their total value locked (TVL). Source: Dune Analytics, DefiLlama. Corrected as of January 12, 2022.
image description
summary
Rollups
summary
Rather than losing Ethereums network effects and momentum by building on a new stack, Rollups are a method of aggregating transactions and computations to a third-party orderer, which then periodically submits proofs of the aggregation As evidence of a valid state transition (called a merkle root) to a bridge contract on L1 to be verified. In this architecture, L1 is nothing more than a data layer.
Since smart contract execution consumes gas on L1, rollups initially have higher fees than sidechains, but this is inversely proportional to the number of transactions per block and is compensated by the higher security guarantees of rollups.
Rollups come in two flavors: optimistic and zero-knowledge (ZK).
Optimistic Rollups
Optimistic Rollups are similar to sidechains in that they are independent networks with their own block producers and smart contract environment. The difference is that rollup leverages the security guarantees of the main chain by submitting the merkle root to the L1 bridge contract.
The word optimistic is used because the network has to wait a few days for execution to complete before submitting merkle roots to the bridge contract. During this time, optimistic rollup assumes that all aggregated transactions are legitimate (“synchronization assumption”) unless a fraud proof is submitted, which forces disputed transactions to be on-chain and the sequencer compares the generated state root with the published state root for comparison.
Submitting fraud proofs is profitable if successful, but the opportunity to monitor the network can be complex and expensive. Availability of validators is a weak assumption that has not been fully addressed, but a viable one is that organizations and users should be funded as a public service to monitor the network and submit fraud proofs when necessary.
Having to wait a week to withdraw Ethereum drives the core of atomic composability across chains, but, like the EVM chains, the Optimistic Network itself is becoming an increasingly thriving ecosystem. Networks like Arbitrum and Optimism are moving towards EVM equivalence using forked versions of the Ethereum protocol, which makes for perfect compatibility with the original Ethereum stack. Rollup dApps will always be standalone instances - independent of Ethereum L1 - but with EVM equivalence, they can be deployed without any custom code and natively combined with any other dApp on the same Rollups.
ZK-Rollups
As with all EVM-based ecosystems, bridging between them requires at least one transactions gas fee, so once ones funds are bridged, the incentive stays there. This walled garden effect is especially strong as more and more utilities are deployed on Rollups, reducing the need to withdraw ETH. A recent example of this phenomenon is Binance announcing that they will be accepting deposits directly from Arbitrum, with plans to enable direct withdrawals in the near future.
Zk-rollups are efficient blockchain compression algorithms that aggregate thousands of transactions on a parallel network, passing these transactions back to L1 with a single proof that a state transition (transaction) is valid. Until recently, ZK-rollups were unable to handle the kind of general-purpose computation required by dApps, and thus were only suitable for simple transactions, but newer protocols such as StarkNet and zkSync offer zkEVM capabilities, 15 times the capacity of Ethereum, very low fees, fully Composability and perfect security guarantee.
L1 smart contract blockchains are no longer directly competing with Ethereum; they are competing with Rollups. - Conti
Continuing with the modular theory, ZK-rollups can be further optimized by going completely off-chain using a solution called Volition, which is coming soon with StarkNet and zkSync.
image description
Security / Liquidity
Security / Liquidity
Fragmentation
Fragmentation
Fragmentation
Fragmentation
If the above scaling solutions do not provide the necessary composability for DeFi, Web3 may need to redesign its stack. In most concepts, the future of scalable digital ledgers involves some degree of parallel processing across shards.
Sharding is a proven method for splitting large databases into manageable partitions across multiple servers while preserving accessible global state. In distributed ledgers, it is a form of merged consensus in which the global network state is divided among subsets of validators, which are usually randomly assigned to shards. In theory, as the number of shards increases, throughput will increase and transaction costs will decrease.
The Ethereum roadmap itself contains plans for 64 shards over a period of time after merging with the proof-of-stake Beacon chain. To keep the data/execution separation for rollups, Eth2 shards will only provide data availability, while code execution will be on L2.
In most implementations, shards can be thought of as mini-blockchains with their own trust boundaries. As we have seen, trust boundaries preclude atomic composability, so some kind of inter-shard message passing must be bridged or implemented.
The practical consequence of this is that, just as it is impossible to have cross-chain smart contracts, it is also impossible to have true cross-shard smart contracts. This is fatal for most dApps, especially ones like Compound that rely on shared liquidity pools from other contracts (eg $DAI). In a sharded architecture without atomic composability across shards, all dApps want to be on the same shard in order to interoperate with each other. Unfortunately, this defeats the purpose of sharding, and is one of the main reasons why Ethereum plans to completely remove the dApp execution environment to L2, so that all contracts can be deployed on a single rollup (within a single trust boundary).
relay chain
relay chain
Shards are efficient because they can process transactions in parallel and asynchronously. The problem is that composability requires synchronization within a single block time. To solve this problem, several projects like Polkadot use relay chains (called parachains in Polkadot) that sit on top of shards and enforce block times to finalize transactions. The relay chain is actually a cross-shard light client, containing only shard headers, just like L1 only contains headers from the rollup. However, the entire system will be limited by the speed of the relay chain. In this way, sharding has not seen much advantage over rollups.
Which way DAO?