New Ethereum talks, every Monday. The week's conference uploads by event, in your inbox.

Loading player…

ETHDay - Skylar Weaver - Scaling Ethereum (without shortcuts!)

CryptoCanalFri, Oct 7, 2022, 12:00 AM

Amsterdam hosted Devconnect for a week, gathering the brightest developers and Ethereum builders. To get a glimpse into this universe, we hosted ETH Day on April 18th at the Transformatorhuis to showcase the best of the week to a wider audience. 🌷 Skylar Weaver https://twitter.com/skylar_eth Leading Devcon & Devconnect with the Ethereum Foundation Learn more https://cryptocanal.org/eth-day/ Join our TG community https://t.me/CryptoCanalCommunity We would like to thank our partners and sponsors that made this event possible. 🧡 Ethereum Foundation https://ethereum.org/en/ Devcon https://devcon.org/en/ Balancer https://balancer.fi/ Oasis https://oasis.app/ Perpetual Protocol https://perp.com/ Lido https://lido.fi/

Transcript

[Music] uh and yeah today we're going to talk a little bit about scaling ethereum i think on the talk it says something about l2s but um yeah talking about scaling ethereum without shortcuts which obviously uh includes includes uh layer one scaling and and layer two scaling uh if you wanna if you wanna track the slides there's a link there you can you can you can watch them as i go along as well um but first a little bit about who who am i uh so just for a little background so i discovered bitcoin first in 2013 uh that was my first like 4a into the crypto space i was 18 years old in college uh and my friends my roommates told me about it so i started developing i was learning how to program started developing all my trading applications uh hooking into mount cox uh and uh very quickly who here knows what happened to mount cox right i think quite a few new so i lost all those bitcoins uh then like sort of uh lost less basically everything i had at that point i took a step back and only until 2016 or so i was introduced to ethereum uh and in 2017 i actually uh attended my first uh my first crypto conference which was devcon in cancun uh and i attended as a volunteer uh and so so huge props to all of the volunteers out here today helping out with each day super super integral but also like also a great way to create a community and to be be a part of a community and to really dive into the ecosystem so i attended devcon 3 as a volunteer and i was absolutely amazed i understood very few very little about what was going on but i knew what was happening was was definitely going to change the world and so basically since then uh i've i've uh i dove into it uh i am now the devcon lead and the dev connect lead so uh this is actually yeah the first time that we've organized devconnect uh so uh welcome to a a an experiment i would call it uh and so so yeah hope you guys are ready for an awesome week we're super excited to have you here uh big props again to illinois the team for hosting the first eighth day uh the first major event of the week and we have a lot of cool events lined up for the week as well so hope you're excited uh maybe see you over at the co-work space later for some social hour uh but i'm not a researcher actually so i do a lot of community education uh both in latin america where i live now and just in general and that includes a lot of communication or education around layer twos so that's what we're gonna talk about a little bit today but first i think it's important to recap like why are we here when what do we to build with ethereum so we want a global credibly neutral system with a system like that we can have things like sound money like ether we can have things like a trustworthy place to store and maintain property rights whether they be digital property rights or representations of physical property rights which in my mind are nfts uh we can have a platform for coordination among many disparate individuals who are working towards a common goal which is what i would consider what daos are trying to do today uh and many many more things like everything from identity to to other financial applications and things like that but in order to have something incredibly neutral we need a thing to be resistant to censorship and uncontrollable by any single entity no matter how powerful that entity might be and to have a system like that we need that platform to be super decentralized operated by many many independent nodes around the world and the reality of the situation is that's not that easy and in doing that in creating a system like that is tempting to take shortcuts uh and so when we're talking about blockchain scaling there are a couple tempting shortcuts to take one of which uh that is actually really well articulated in in vitalik's blog post here called the limits to blockchain scalability if you scan this qr code you can go and check that out read that later i would recommend it for all but essentially one shortcut that exists in blockchain scaling is sacrificing the ability for regular users to be able to run nodes to be able to run full nodes and so when i talk about nodes here i'm talking about full nodes which basically means you are downloading incoming blocks to your to your computer and you're validating you're verifying that they are correct i'm not talking about staking nodes i'm not talking about the need to like actually stake and support the network i'm talking about being able to run your own full node and a shortcut that exists that a lot of that that is tempting to take in blockchains is to sacrifice the ability for regular normal users to be able to run their full nodes uh and the way they do that is they increase the block size and they increase the block times they advertise super fast scaling they have super cheap fees but in turn they are sacrificing decentralization now the hard way is to maintain the value that users should be able to run their full nodes which requires more advanced techniques and can you cannot just increase the block size and increase the block time but you could scale while trying to maintain decentralization so this is the way that we're going to talk about so great make it so that average users can run a node the ethereum roadmap prioritizes this and we need to improve it more to be honest we need to make it much easier for average users to run a full node and a lot of the upgrades coming to layer one are are targeted towards this as well so what's the problem the problem is gas is expensive so the throughput on ethereum on ethereum layer 1 is intentionally constrained so it is intentionally constrained because we want to make sure it's easy for average users to run a full node so we want we want to be able like an average user has an average computer and we need to be able to to create a worldwide system that doesn't require more resources more computing power than an average user has to run so we're intentionally constraining the throughput in ethereum but what does that mean that means that it is now expensive to use because a lot of people want their transactions inside of it and so we run into this problem where layer 1 is expensive because we are not sacrificing decentralization so that brings us to like the scalability problem and maybe like more explicitly why is gas so expensive if we remember what gas is again right gas is the is is is is a a combination of where block space is available versus demand for that block space from the people that want their transactions and the problem being a lot of people want to include their transactions on ethereum uh but the space and speed is intentionally restricted to allow average users the ability to run the nodes so that space that is available becomes much more expensive so to quickly run through it i guess there are two more or less ways to ride to scale a blockchain they're both scaling via layer one and scaling via layer two uh and so on the left we'll jump into scaling via layer one really really quick here uh and how we will not scale via layer one is we will not simply make the blocks bigger we not simply make the blocks faster because then you're making you're jacking up the node requirement for for average users and average users won't be able to run a full node uh here's an unknown other blockchain that exists out there that advertises them being very decentralized but more than that super fast so you could see 2 000 some transactions per second uh average cost per per transaction um the the total transactions that they have processed and this is on like their front page like right right there and this is what they want you to know but what they don't necessarily tell you behind the scenes is like the requirements to run a node and so to run a node on this network on this on this blockchain you need a cpu with 16 cores in it uh they recommend the ram you have on your on your node is 256 gigabytes or more how many people have gigabytes of ram on their computer they're walking with right now you know or or maybe at home and then you have uh you need it you need a not only just that but you also need networking so you need an internet service that has at least 300 megabytes per second and they recommend a gigabit up and down symmetric like that is something that's i think possible but difficult to get in city centers uh and and for most of the world especially developing countries just straight up impossible to get for average people so we will not one does not increase so one does not simply increase block size and block times to lower transaction fees uh how we will scale however is trying to maintain true decentralization maintaining censorship resistance and trying to keep the power in the hands of individuals so our plan for for layer one scalability is is complex and it takes time because we're trying not to take sacrifices so vitalik put out a a like a diagram of like one perspective of the road map which is like this community road map that like the ethereum community has has has generally agreed upon uh and if you want to scan the qr code it brings it right there to that to that to that tweet but zoomed in a little bit further we can see we have the merge the surge the verge the purge the splurge and so they're kind of goofy names realistically but each one of these the idea being here that each one of these brings separate upgrades to the layer one that either increase security or increase decentralization or make it easier right to make to run it to run a full node or increase like maybe maybe like from an mev perspective so they do different things uh and each one of them is fairly depth but if you scan this qr code you can go check out a lot of resources about each one of these if you're curious and for those of you who are here for tim baker's talk this morning he dove in a little bit deeper about the layer one uh road map and so maybe you can re-watch that as well so i'm not gonna spend a ton of time on the layer one scaling what i'll talk a little bit more today is layer two because cool layer one upgrades are incoming but gas is still expensive now what can i what can i do today to get to get cheaper fees so we'll talk a little bit about the second way to scale a blockchain which is scaling via layer twos zika roll-ups so layer twos in my mind are are a layer two is something that inherits the same security that shares security with the main chain and so i would say not all scaling solutions are created equally i think depending on like the diagram you look at or who you talk to layer twos could incorporate different different types of scaling solutions so some would say that side chains are part of the layer two scaling some would say that like validiums and volitions and these other types of of uh of scaling is are part of it but uh for me i would say layer two is something that inherits shared security uh and by that i mean that it is um basically like the validators of the layer two system uh cannot rob your funds or center you even if they wanted to and that's the case in side chains many sides that exist and other types of scaling solutions so here we'll talk about layer two as being primarily roll-ups uh and diving into a little bit about roll-ups so this talk came about because essentially uh we had we talked about eat day right and like we're gonna cover a bunch of like high-level things that were happening in ethereum and i was like ellie we can't have each day without talking about scaling and i thought without talking about the gas fees and talking about roll-ups uh and so it's a really high level description but there's some links here so you can go deeper into learning more about them but for those of you who maybe haven't heard about rollups before roll-ups the idea with roll-ups are that they're separate chains outside of ethereum that move the difficult and costly computation off of layer one and so these separate chains like you basically imagine if we were all on the separate chain we can make a bunch of transactions among ourselves and at the end of these transactions the final state gets gets submitted back to layer one uh and um an important part about layer twos or about rollups in particular is instead of creating its own security it inherits the security and decentralization benefits that the main chain has which for ethereum is fairly great uh and if a rollup provider wanted to steal your funds they wanted to steal your funds they couldn't because of the crypto economics or in zika rollups the cryptography that exists with these with these rollups even the rollup providers couldn't steal their funds if they wanted to that's not the case with side chains that's not the case with alternative layer ones and so when we talk about scaling ethereum through layer twos we're really excited this is why the community is really excited about rollups and if they stop processing transactions the rollup providers or if they want to censor you specifically there's always an ability to exit back to the main chain exit back to layer one so even if they wanted to steal your funds to censor you they run into challenges and they're not able to uh and why are they called roll ups because they essentially roll up many transactions into one final state and submit that back to layer one so why use two why use roll-ups well they're cheaper there's higher throughput and they inherit the they inherit ethereum's security and decentralization benefits um and they're censorship resistant and secure the provider cannot rub your funds even if they wanted to and with other types of types of scaling solutions like side chains and other things you are trusting a different and often weaker set of validators and security assumptions uh so here's one example if you look up there on the right that's l2fs.info and you can see that this was maybe taken a few months ago late last year and at that time the swap tokens on unitsprop it cost 30 on optimism and arbitrary and looping it costs two dollars and today that would cost even less because they've optimized even farther uh and so quickly about the two types of roll-ups so after computing optimistic roll-ups and zk robs are like the two main types that exist out there in the ecosystem you've probably heard of me before maybe some of you know them very deeply uh but those are you for those of you who don't so optimistic roll-ups basically the way they work is uh after they compute all the transactions they submit two things back to l1 they submit the final state of those of those of those transactions back to layer one and they submit a little bit of stake in ether back to layer one as well this is the role of provider submitting this then there's a contract on l1 that accepts it without knowing whether or not this the result of those transactions is actually correct the contract is an optimist uh and so what what happens is those funds sit in that contract for seven days uh or whatever amount of time the rollup decides and in those seven days anybody can verify whether or not that final state transition is correct and if it is not correct anybody can submit a fraud proof that group that proves that is not correct uh and in that case um the if if it's indeed not correct the challenger wins the stake and if it uh if it is correct then the tokens are freed and everything works like normal so that the case in which the fraud proof is submitted and the challenger actually wins is like the the odd case out there most transactions probably are um are are good but uh but yeah that's more or less how optimistic roll-ups work zk roll-ups work a little differently where the roll-up submits the same final state uh except with a cryptographic zero-knowledge proof that the layer one contract can verify immediately the way the zero-knowledge proofs work you don't actually need to uh submit a stake or wait for anyone to verify the contract itself can actually verify whether or not the proof was correct uh and so the downside with that is or the plus side is you don't need to wait seven days the downside is it's also quite a bit more complex so maybe a little bit about pros and cons with the optimistic roll-ups versus zk roll ups the pros are the optimistic roll-ups are available now for everything you can do on layer one um the con is that if you want to wait your fun wait if you want to withdraw your funds to l1 you need to wait uh and it depends on the roll up but uh sometimes it could be seven days or it could be shorter um in some perspectives it's not that bad because a lot of the activity will be moving uh two roll ups in general and we'll be living in a multi-roll-up world uh potentially soon on the other hand zk roll-ups you don't need to wait uh to withdraw your funds back to layer one uh because it's proved immediately with crypt cryptography and uh but the con is that it's a little bit more complicated and you still cannot copy and paste your solidity code from layer 1 from layer 1 dap into azure knowledge proof so they're both working on improving these um zero knowledge proves for instance are working on zika evms uh optimistic roll-ups are are working on making things more efficient um and they both have their different pros and cons right now and i say we're still early i think most of these launched late in like late last year i believe uh and so um yeah i'd say we're still early with the roll-ups but this is sort of the way that the the ecosystem ethereum is moving is moving towards these uh this roll-up centric roadmap so i think in the future i think it's very likely that we'll be living in a cross-roll-up world where all of the roll-ups have shared security with ethereum and um the roll-ups only need to focus on execution they can maximize this execution and like the in their efficiency with it they can start doing paralyzation of transactions and the security is managed by layer one the entire time uh and the gas costs end up being split across many users amortized in the case of zka roll-ups possibly also with optimistic roll-ups as well and perhaps like we'll see the majority of us normal users interacting with ethereum via roll-ups not via layer 1 having cheap fast transactions but still still inheriting the same security that ethereum provides and inheriting the same decentralization benefits that ethereum provides so that's what i would say let's say a couple key takeaways here are one it's important to allow average users to run a node not just make it possible but make it super easy for the average lazy user to run a node um two is many projects sacrifice that ability for scaling be wary of the billion transactions per second or super cheap transaction fees marketing if an average user can't run a node in my opinion is not decentralized enough and three scaling without sacrificing decentralization is hard there are both layer one and layer two ways to scale uh real l1 and scaling needs advanced techniques and we're working on those in progress in different upgrades that are coming to ethereum and l2 scaling like rollups are available now so if you want cheap fast transactions while still inheriting the same security of ethereum you can use rollups so for users use them for developers deploy to them whether it be optimism arbitrom zk sync start connect aztec and many more uh and a couple resources that i'll leave you with before departing is l2b which is a great resource for analyzing different rollups that exist out there uh analyzing both like the risks and their their market share then l2 fees for analyzing like the different fees for the roll-ups versus ethereum so you can see what it costs versus where each tps is also interesting to see how much of like the transaction per seconds are going how much of the transactions on ethereum are going through roll-ups in comparison to ethereum mainnet uh and just a reminder that we are very early in this entire thing rollups just launched uh and i do think that we as an ecosystem are like we're super excited and and uh excited about rollups in general and layer two scaling in general so i would encourage you all to uh to explore them start using them um and uh yeah that's what i would say so if there's any questions i don't know if we have time for questions maybe not because i think we're a little tight on time here but i'll be walking around if not and you can come find me so i appreciate all of your time and see you at all the other events throughout the week throughout devconnect and thanks again to ellie and the team for putting on this amazing event [Music]

Automatic transcript — names and jargon may be misspelled.