Blockchain CBSA – Objective – Ethereum Part 2
- Ethereum Gas Estimates
I’m over here at the Ether gas station. The link is here. It’s basically Ethan info. I’m over at the home page here. You can see here that it’s got the gas time to price estimator tells you the approximate use case and the cost involved tells you the count by gas price. In other words, again, percentage of transactions fall into a specific range. It seems like between four, but less than 20 seem to be about 60% of the transactions. Sort of an interesting thought there. You can see that this is the top ten miners by miners that are mining Ether. Now this sort of tells you up here the gas price standard for Ghee. It’s actually we. I never say that right, but we is really how it said.
The standard cost for a transfer is zero point 57. Right now the low bid that you could put would be about forty three cents and the safe low would be as far as three. When it comes to the number of GUI, the wait time is there. Again, it really just depends. It could be dependent on the time of day. Again, gas price, right, confirmation time. If you’re willing to pay more, you’ll get a better confirmation time. So let’s go ahead and play around with the TX Calculator for example.
Now the TX Calculator will allow you to put in how many transactions do you think you’re going to be making in the blockchain? Now again, as an architect you’re not going to have an idea, but your developers are going to have a good idea. Let’s say for example, I’m going to have 40,000. This is a big app. And I put in is that 400,000? Let’s just make it 40. So I put in 40,000 and I go ahead and adjust the gas price if I want the fastest. That’s telling me probably 20 Wii. Above 20 Wii, average is going to be four Wii, and then cheap will be three. We’ll just leave it on average.
Now I go here I go to submit. You could see that right now that the estimated cost of running that application would be about certainly less than a dollar. And Ether will be let’s go ahead and make this bigger numbers to see. We put in $400,000 right now. You can see that it’s going to cost about one dollars and change to run that transaction. But if I go fastest, you can see that it goes up five times for the fastest possible transaction time. But if I want to go the cheapest, I can then bring it down to less than one dollars. And that way when you’re designing applications, you can figure out what it’s going to cost to run that application.
And then we have what’s called the Transmit Pool division. And this is just telling you as far as the percentage of blocks, the number of transactions, what was transmitted in five minutes or 20 minutes. That way you get an idea of transaction speeds. They have a price watch list as well. They have the gas burners. Now the gas burners is sort of funny. These are really the sort of like the nodes that are again putting in the most. These are actually the wallet addresses that are really putting in the highest number of transactions.
So this is ethergas info. I encourage you to take a look around. Got some neat features to look at and capabilities to get an idea of what you’re doing. You could also change currency here. They only support a few currencies, but it does the job. And then over here, you go over here to estimate confirmation time. As you see, if you want to get different confirmation time you can see that the fee is going to go up as well. You can increase the gas size again, it’ll increase the price eventually. This isn’t an estimator as well. With that said, just want to show you how to estimate a smart contract price to run it on the blockchain. Or your DAP, I should say.
- Ethereum Browsers
Okay, let’s talk about Ethereum browsers and how we could develop and access our D apps. Now, Mist is the browser essentially for decentralized apps. It’s also known DApps essentially is known as web 30 supports ie or google chrome. Mist is still in heavy development and again may not fully be supported in some situations. Now, Mist is a full mode. That’s one of the things to pay attention to. So you need to download the full blockchain. Now it also integrates with swarm as well and it is flexible as far as the desktop application that you’re using as well. Now MetaMask is a bridge that allows you to visit the distributed web of tomorrow.
Basically, MetaMask is a Chrome extension that you can download and add to Chrome. And what’s really nice about MetaMask is that you don’t have to download the full node, you don’t have to download the blockchain. It’s basically storing basically your information locally in your browser memory. It allows you to develop and run your D apps locally and you can also select your test net or your main net. It’s really a great tool. There was a demo earlier in the class as well on MetaMask. So if you haven’t seen that or played around with it, do check that out.
Now MetaMask is also again a very solid wallet as well. And in the demo you’ll see that I went through and I transferred funds and ran a test application as well. And again you would add that to your Chrome browser. Then there’s also parity. This is a lightweight browser and allows you as well to run your decentralized apps as well. Now, it does have a web three D app browser that supports as well. Let’s go ahead and move on to the next module.
- Ethereum Development
Okay, well, let’s go ahead and talk about Ethereum development. Now, Ethereum of course, has specific tools that are available, some of which are basically dedicated to Ethereum, some of which are not. Let’s go ahead and talk about a few of these. So when it comes to languages generally, the most common language that’s going to be used to develop with Ethereum is going to be Solidity. We’ll talk more about Solidity here coming up in a few minutes.
Then we have Serpent and then we have Mutant as well. As far as IDE environments generally, most developers are going to use typically the Solidity browser or Ethereum Studio clients are available gap, F, Parity, Ethereum Wallet as well. Storage could be IPFS warm or storage a as well. When it comes to Dab browsers, generally MetaMask or Miss will be what you will see. Again, we have a demo on MetaMask, for example. Now. First test nets. One of the things before you deploy anything, of course, is to test it out. And to deploy on a test net, you’ll need to have test Ether.
And each of the test nets have different requirements to get that test Ether. So you may want to check that out based on which test that you’re using. For example, like Rob scenes, for example. Now, when it comes to front end tools and back end tools, if you’re developing the front end and there’s your client application again, the application could be in whatever you feel like. It could be an HTML if it’s a web based app, CSS or JavaScript. Just some examples that could be used. Now, the back end is going to typically use Solidity or Serpent. Now, with Solidity, you can go ahead and download or you could also compile in your browser as well. So you have some options there. Now, Solidity, for those not familiar with it, this is really the language behind Ethereum. It was actually specifically designed to utilize the EVM. And this is what really makes it really easy to develop on, is that the network basically protocols are already there. It’s already connected essentially in that sense.
So you don’t have to go in and worry about how to configure the blockchain network because again, it’s designed to connect to the EVM. The ethereum. Ethereum based applications are written in solidity. Solidity was proposed in 2014 by Dr. Gavin Wood for ethereum. And again, this is done before it actually went live. Now, Solidity for those developers that are familiar with JavaScript and C, it’s sort of a hybrid in the sense that it has some features of JavaScript and it has some features of C as well. Now, when it comes to Solidity, it is a new framework, but it’s probably closer to JavaScript than C. Basically. Solidity is an object oriented language very similar to C Plus Plus and C, but JavaScript again, is based on HTML.
Solidity was really designed specifically for Ethereum apps and it was meant to run on the ethereum blockchain. Now, JavaScript again is really a universal language, and what makes it useful in the sense that it’s similar to JavaScript, is that there’s a wide developer audience that knows JavaScript. So this is a huge benefit when it comes to APIs. Basically, JSON is a lightweight format that can be used, of course. And if you’re going to talk to the node from a JavaScript app, you want to use the web three JS library. This is what has the RPC methods. Now, RPC is what that’s removed procedure calls for those folks that may not up be familiar with that. And here are some practice questions to help enable you before you take the test. Let’s go ahead and move on to the next module.