Hedera: Leaderless dApp Development
ETHDenver 2023 · February 2023 · 17:30
An ETHDenver 2023 talk covers Hedera's approach to leaderless dApp development on its hashgraph-based distributed ledger, an alternative consensus model to blockchain that Hedera uses for speed and fee predictability. It looks at how developers build decentralized applications on a network without a traditional leader-based validation process.
Speakers
Topics
From ETHDenver 2023, hosted by ETH Denver.
Transcript
okay thank you guys um like the embassy said I really appreciate you guys getting up early and coming out with my talk um it's a big ask 9 15 on a Saturday so really appreciate it um I'd like to start my talk with a little bit of a thought promotion quote generally um and this is one that always surprises me a little bit um on face value it seems really simple but it's something that quite often as communities we can kind of get wrong so I'll contextualize us a little bit for you before I jump into the main talk um so web3 is you know bigger than one chain one network um and often you know the tribalism that we can kind of see in web 3 kind of cannibalize this as a success a web 3 for all of us
and it's really only by working together that we can Elevate one another Elevate web 3 and have us all win so I kind of analogize that a little bit to when somebody is buying something if you think so it could be anything let's say a car if you've picked a few cars out that you like you go to the car dealership if they suddenly start hammering the other brands that you're looking at you go to the other car dealership they how many other brands as well as a buyer you're going to be really confused you're not going to engage right so I see that a little bit in the same way with web3 if we continually kind of hammer each other it's not going to kind of give people the confidence to come on board so keep that in mind and as I move into my
next slide shortly I'm going to tell you a little bit more about how hedera lends into that as well I'm just going to introduce myself a little bit first so I'm Matt Woodward I'm the head of developer relations at swirled slabs for hedera um I absolutely welcome you to connect with me um as you as you'd like I'm basically a full stack developer I have been for over two decades throughout my entire career so far um and that includes included software architecture software integration as well I've also had the pleasure of running my own companies of building my own startups so when it comes to software development Innovation strategy it's something that I've really got battle
tested with so I've got you covered so I'd like to talk a little bit today about cross chain or multi-chain development um I know from having been in a space for a little while now that developers want to build a cross chain and that sort of comes across from a number of different needs and wants it might be simply to reach a new audience um it might be to migrate entirely to a new platform you might be working with a channel partner that you want to connect with that's working on a different chain or very simply you might just want to leverage some very specific Network benefits now evm compatibility uh and more so equivalents are going to be really key
in letting developers do that um in web 3. so um hedera's Journey on this kind of started well over a year ago um as we migrated our evm over to the hyperledger Bay Zoo um evm and that allowed us to maintain parity with the EV uh with the ethereum mainnet evolutions uh such as the evm container formats the op codes um the pre-compile contracts as well we took that one step further and we integrated our own token service into the evm as well so our token service known as HTS or hedera token service and that means that you can essentially treat the tokens through the ebm in
exactly the same way as you would treat ethereum tokens today so erc20 or 721 finally when we were doing that integration we also increased the performance uh to 15 million gas per second that gives us roughly 350 TPS for smart contracts alone now I'm just going to pull out at this point and highlight that there is a balance here with having that familiarity with being able to deploy a smart contract using solidity on an evm compatible um smart contract Service like this and getting that kind of performance there's also an option for you on hedera if you want higher performance you can use our native Services um those will currently operate at 10
000 TPS instead and are often a faster and quicker way of being able to act to access our Network um so I'm just going to share what I mean by that a little bit just to give you some context so this is a hedera network as it stands today and the Network Services you can see right across the middle in bright pink so it's hard to miss them right we've got a consensus service up there that is uh provided to give you um verifiable time stamps and event ordering and that can be used on web 2 or web3 platforms uh we've got our token service and that's everything to do with fungible non-fungible tokens uh token management so creating minting transferring burning all of the things
that you love to do normally with it and then we've got the evm compatible smart contract Service on the far side as well over there those all run on top of the hashgraph data structure and consensus mechanism that we currently have on our mainnet and obviously it goes unsaid that the applications then get built on top of those that we see today so the native Services I was alluding to before are essentially the consensus and the token Services they will happily run at 10 000 TPS and I've said they're very much the quickest and the cheapest way of you being able to use our Network that said it makes subtle sense that those might not be the most comfortable choice for
you when you're coming across chain so what we've done at hedera is to cater for the Json RPC API calls through which a lot of tools libraries uh wallets uh will actually call through and want to access the network and the evm and we've done that through creating this Json RPC relay interface that basically sits there at on top of our network if you like so as those transactions come in they get wrapped as ethereum transactions and then get redirected through to either our mirror nodes where they might be querying for information from the history of what's going on on The Ledger or actually sent over to our consensus nodes where you might actually
be writing a transaction to The Ledger instead now this layer has been written because fundamentally there are differences obviously between the two sort of ecosystems and I just want to share a couple of those with you so that you can kind of understand what that might mean um so think about network access to start with hedera behind the scenes uses grpc for its communication between nodes so if you haven't checked that out please do it's a great kind of uh performance protocol so that's the reason that we chose it but obviously most of the ethereum world uh Atmos wallets Etc really use Json RPC as our communication protocol and there's nuances around that that some of those apps rely on
similarly for us from an account point of view accounts on hedera aren't tied to keys so what I mean by that is that the keys can actually be rotated on your header accounts but more so than that as well there's actually quite a few different complex uh variations that can go on too so you can have a multi-signature accounts where you might need more than one person to actually sign a transaction you can have threshold accounts where you might need three or five people to sign it for example and you also could have a complex tree of signatures that might mirror perhaps the sign off structure in organizations and that type of thing perhaps um and look out of the box those aren't something that have an equivalent on
ethereum right now and so tools like metamask wouldn't really understand what some of those protocols look like so it's really important to make sure that from an equivalence point of view and from a cross-chain point of view we have this kind of interface that allows those tools libraries to interface with hedera in a way that's familiar for them and obviously that's kind of part of what it does for us to sort of bridge the gap between those differences now with obviously having an AVM compatible smart contract Service having a Json RPC relay to interface with transactions from Cross chain the doors were essentially wide open on hedera now if you have a look for you to learn I've used a build on it for you to explore and most importantly future leverage the
network benefits where it fits for your kind of purpose so I just want to talk with you a little bit about what that might look like what the impact might be now in terms of capabilities hedera already provides you with the capability of building reliable cost-effective apps that are fair to users so somebody's kind of really talked to that in terms of the low predictable fees so our transactions are fixed to the US dollar and that kind of means that even though our token or coin price map might change your operational costs don't so as somebody building and deploying an application you can more readily predict what the costs are going to be for you over the course of you actually deploying and running that application which is really important for those of
you that are sort of looking at this through the business lens and trying to make sure that your cash flow is working appropriately now there is obviously a high transaction throughput I've mentioned that before and really from an app Dev point of view this is really about making sure there is room for you to scale and grow everybody wants our application to be successful they want more users they want more use that being your trajectory you need to make sure you have room for that growth on a network that you choose we've got that growth capacity there as I've said and finally with abft security and fair ordering you can make sure that your application transactions are ordered fairly so I'll talk more about that in a second so I want to talk about how this might
look different for you as a builder what are some of the considerations that might be different so technically to start with there is no Mema or transaction pool on hedera it just isn't required when those transactions are submitted to a node they stay in that fixed position that they are received before going to consensus more so there is fair transaction ordering as I alluded to on the last slide so transactions going through consensus are ordered using our virtual voting protocol before then obviously being executed so there is no need for you to deal with elevating the priority or transaction for you to go through consensus and actually achieve a
successful submission to the to The Ledger it actually will be executed fairly all of them are treated with equal priority and uh therefore sequence value in order that they were received then one thing I will note just before I mention this next part as well is to surround a fair transaction ordering if you think about that in terms of some of the logic and some of the code that you might build into applications to cater for how that priority Works around transactions that wouldn't be required on hedera and in my book from somebody that's written in this fair share a code last code is better so that's a good thing now finally there is continual transaction execution so this is kind of
a really important point because hedera is a leaderless network so in that sort of sense it lends itself into having those transactions submitted to a node being ordered fairly through virtual voting and then being executed straight off the back of that so you have continual transaction execution it means that you get a fast transaction confirmation time typically three to five seconds and that's really important for those of you that might be building high performance use cases that require that are required to be responsive think gaming think mobile applications you don't want users or customers sat there waiting for a response and figuring you know what what might have happened Etc so you get the benefit of that on our Network too
now why should you care about some of these things when you are building applications so when applications can achieve sustainable viable High throughput consistently it means that the bumps in your customer experience are minimized all of those things that happen when you've got lots of customers using it and it starts falling over come away that's kind of quite nice right so it means you can focus on this the customer experience the things that bring people to what you're building you can make sure that they have a great experience and they enjoy what it is that you're delivering to them that's the most important part and the most important time you can spend on what it is that you're putting together
the next part is because of what I've shared with you you don't need to pay elevated fees to increase the priority of your transactions to get those accepted by the network for them to be processed quickly so that you can give a great customer experience simply you pay less as a builder your customer pays less as well and they essentially would use your application more and finally as I've said you can guarantee Fair ordering now why is fairness important uh I probably don't have to labor this too much but in essence as soon as you introduce some of these Concepts into your application so think ethics where you're dealing with cues or service Lanes legal with
auditing items or compliance issues stock where you're managing different items going through a supply chain perhaps or availability of them through a store and then anything that is time or cost sensitive then you and more importantly your customers are going to care about having fairness in the equation now fundamentally nobody likes having their social justice button pressed over and over and over if you're a builder and you've got an application out there and you haven't had somebody moan in this way yeah I can rest assured that it's coming as soon as you start scaling out and growing your
business and have enough customers on your platform people start picking out things that aren't quite right in your application so things like you know there were next in queue they thought they were going to get it they didn't get what they thought they were going to get they were desperately trying to grab a ticket or mint and nft and it didn't happen so it's really important from a fairness point of view that you consider that if you don't like it in your experience in web 3 as a builder as a developer then customers are really not going to like it either and that's really important to keep front and center as web3 is adopted more and more on scale now our journey um as hedera from an evm equivalence
point of view is a network gives you the option to tap into building high performance applications as we've talked about the leaderless they're fair and they execute transactions in that consistent and fair order and that concept is going to become more and more important as more people come into web 3. see how smooth that was I know you all liked that bit okay I just want to summarize because I can't talk to you all day despite the fact that I would enjoy doing that herdera is obviously on a journey to evm equivalents we already have an evm compatible smart contract Service that I.E you can write smart contracts in solidity you can leverage the 350 TPS
that's there right now on our evm compatible smart contract Service but noting that if you don't need the complexity of specific smart contracts nuances perhaps that you would require for running Adept for example there are native Services you can access directly that are faster and cheaper we have a Json RPC relay that will enable you know apps have been developed with ethereum only requirements in mind along with wallets tools libraries that only use Json rpc2 okay and finally Dara uses a leaderless consensus mechanism and it ensures that your daps are fair
to your users so when am I would encourage you to come and talk to us at our booth at 555 if I've touched on some things that have been inspiring or have raised questions for you happy to continue the conversation there you're also welcome to tap into the resources I put on screen at the moment around the getting started um section of our website that we'll talk you through a few resources there you can join our community over on Discord and if I've inspired you enough to want to start building on hedera and having a play you are welcome to go and get yourself a test net account those are routinely topped up to 10 000 test H bar every 24 hours that gives you plenty of
scope for being able to battle test something that you might be considering bringing over to the network or simply to have a play with it I want to thank you finally for your time this morning and for coming up quite so early once again um I've really appreciated it and uh I'll leave that there but I'm happy to take any questions after the talk thank you very much okay [Applause]