The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439....

33
The Promises and Challenges of Ethereum Off-Chain Scaling Xiaozhou Li Celer Network

Transcript of The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439....

Page 1: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

The Promises and Challenges of Ethereum Off-Chain Scaling

Xiaozhou Li Celer Network

Page 2: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Internet (web 2.0) vs. Ethereum (web3.0)

global information transfer global value transfer

One second:70K Google searches,millions of emails and messages, 60TB data transfer ……

One second:10 transactions

Page 3: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

global information transfer global value transfer

One second:70K Google searches,millions of emails and messages, 60TB data transfer ……

One second (goal):??? transactions

Can Ethereum match the scale of Internet?

Page 4: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

global information transfer global value transfer

One second:70K Google searches,millions of emails and messages, 60TB data transfer ……

One second (goal):hundreds of millions or billions of transactions

Can Ethereum match the scale of Internet?

Page 5: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Billions of TPS

How could we ever get there?

Page 6: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Scalability

On-chain Limit

Mass Adoption

Efforts

Where we are

blockchain

dApps

Page 7: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

blockchain

Scalability

On-chain Limit

Mass Adoption

Efforts

Where we are

off-chain scaling

dApps

Page 8: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

How does off-chain scaling work?

off-chain transfer on-chain settle

Concepts: state channel, sidechain Only resort to on-chain consensus when absolutely necessary

Secure: blockchain acts as the “supreme court”

Fast: independent operations across nodes, fully scale-out

Private: most activities only seen by participants

Page 9: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain payment channelOn-chain bond contract

Deposi

t 10 E

THDeposit 10 ETH(2 on-chain transactions)

Page 10: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain payment channelOn-chain bond contract

(N off-chain transactions)

$X $Y#n

Balance Proof

Page 11: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain payment channelOn-chain bond contract

Subm

it sta

te pro

of

(On-chain settlement)

agree

$5

$15

#47

Page 12: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain payment channelOn-chain bond contract

disagreeSu

bmit

state

proof

(On-chain settlement)

$5

$15

#47

$2

$18

#49

Page 13: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain payment networkOpen up great opportunities for ultra high throughput p2p micro-payments

Page 14: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain chess duelOn-chain bond contract

0.1 ETH if Alice wins

0.1 ETH if Bob winsAlice Bob

Page 15: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain chess duelOn-chain bond contract

State Proof

Page 16: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain chess duelOn-chain bond contract

0.1 ETH

Win! Cooperative

Zero on-chain operations when everyone is cooperative

Page 17: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Example: off-chain chess duelOn-chain bond contract

Win! Uncooperative

Only resort to on-chain consensus when absolutely

necessary

Dispute

State

Proof

Page 18: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Bright future, challenges remain

• How to support generic operations with minimal on-chain footprint?

• How to route value transfers efficiently in off-chain networks?

• How to help developers to easily build and operate off-chain dApps?

• How to make off-chain states always available for on-chain disputes?

• How to obtain enough liquidity to run an off-chain service?

Celer Network

cStack

cEconomy

Page 19: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Celer ArchitectureCeler Network is an Internet-scale, trust-free, and privacy-preserving platform where everyone can quickly build, operate, and use massively scalable decentralized applications. 

Blockchain

dApps

Celer Network

cChannel

cOS

cRoute

cStack

+

cEconomy

State Guardian Network

Proof of Liquidity Commitment Mining

Liquidity Backing Auction

Page 20: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cChannel: Generalized dApp Support

• Generic off-chain state transitions o conditional payment o multiparty gaming o second price auction o high frequency exchange o ...

• Pure off-chain contract o no on-chain deployment when everyone cooperates

• Multi-hop state relay

• Formal specification and verification

cChannel

cOS

cRoute

cStack

Page 21: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cChannel: Generalized dApp Support

cChannel

cOS

cRoute

cStack

on-chain stateoff-chain state state dependency

Alice will pay Bob 1 ETH if Carl

wins

Bob will pay Carl 1 ETH if Carl

wins

Alice <---> Bob Bob <---> Carl

Alice vs. Carl

Page 22: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cRoute: Highly Efficient Payment Routing

• Provably optimal throughput

• Transparent channel balancing

• Fully decentralized

• Failure resilience

• Privacy preservingcChannel

cOS

cRoute

cStack

Page 23: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Why off-chain payment routing is challenging?

• Link state changed by every payment

• Max rate ranges from zero to infinity

• Network is constantly changing

X Ybalance of

Xbalance of

Yoff-chain channel

• Link state not affected by past transmissions

• Max rate is fixed (e.g., always 1Gpbs)

• Network is relatively stable

X Ybandwidth

data network link

Off-chain payment networks are fundamentally different from data networks

Most distributed routing algorithms for data networks are hard to converge in off-chain networks

Page 24: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cRoute: Highly Efficient Payment Routing

cChannel

cOS

cRoute

cStack

Forwarding Layer: Distributed Balanced Routing (DBR)

Policy Layer: Flexible Policy Configuration and Enforcement

Overlay Layer: Privacy-Preserving Onion Routing

Page 25: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cRoute Simulation Results

77 nodes 254 bi-directional payment channel Poisson arrival with random src-dst

Payment throughput Channel utilization

Page 26: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cOS: Development Framework and Runtime

• Provide common design patterns

• Enable “write once, run anywhere”

• Bridge on-chain and off-chain byte code

• Figure out state dependencies

• Track and dispute off-chain states

• Support concurrent off-chain dApps

cChannel

cOS

cRoute

cStack

Page 27: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cOS: Development Framework and Runtime

cChannel

cOS

cRoute

cStack

Page 28: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Scalability does not come for free!

Off-chain scaling is introducing new tradeoffs

Page 29: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Bright future, challenges remain

• How to support generic operations with minimal on-chain footprint?

• How to route value transfers efficiently in off-chain networks?

• How to help developers to easily build and operate off-chain dApps?

• How to make off-chain states always available for on-chain disputes?

• How to obtain enough liquidity to run an off-chain service?

Celer Network

cStack

cEconomy

Page 30: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

cEconomy completes the off-chain ecosystem

State Guardian Network

Proof of Liquidity Commitment Mining

Liquidity Backing Auction

disagree

Settl

e

sync

Offline

$5$1

5

#47

$2 $18#49

Ensure off-chain states are always available for on-chain disputes

Page 31: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

State Guardian Network

Proof of Liquidity Commitment Mining

Liquidity Backing Auction• Off-chain service providers crowdsource liquidity • Reward committed liquidity backers • Ensure 100% safety for end users

cEconomy completes the off-chain ecosystem

Incentivize an abundant and stable liquidity pool

Page 32: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Build and operate Internet-scale dApps on Celer Network

Blockchain

dApps

Celer Network

cChannel

cOS

cRoute

cStack

+

cEconomy

State Guardian Network

Proof of Liquidity Commitment Mining

Liquidity Backing Auction

Page 33: The Promises and Challenges of Ethereum Off-Chain Scalingethis.unitimes.pro/file/1472538728349439. Xiaozhou Li 2-watermark.… · • Provide common design patterns • Enable “write

Thanks!www.celer.network