Chapter 2. Blockchain Building Blocks

Vitalik Buterin was only 19 years old when he changed the world.

Born in Russia, Buterin’s parents emigrated to Canada when he was six years old. It was clear that Buterin was a child prodigy: educators quickly recognized his remarkable talents, and moved him into a class for gifted children, where he excelled in math, programming, and economics.

As a teen, the young Buterin was introduced to bitcoin by his father, a computer programmer. While he was fascinated by the technology, he saw bitcoin not as an end in itself, but a means to an end. What if you could develop applications on top of bitcoin—essentially turning bitcoin itself into a platform?

Buterin proposed a new kind of scripting language that could be built on top of bitcoin. (As an analogy, think of his idea like Android scripting languages, which make it easier for developers to create Android apps.) When he wasn’t able to gain critical mass for his idea among bitcoin’s core developers, he started his own project.

Like Satoshi before him, Buterin described his idea in a white paper.1 Announced in 2013, he described his project as a general blockchain platform, with a simple scripting language that would allow developers to rapidly create new blockchain apps. It would come with its own built-in units of value, its own “digital currency.” Also like Satoshi, Buterin attracted a small team of developers around his idea, who helped him prototype and launch the platform. The project quickly attracted a network of volunteers willing to build the network because (like bitcoin) they were rewarded with small units of value for hosting nodes.

Buterin called the project Ethereum, after ether, the hypothetical invisible substance that permeates the universe.2 The unit of value—the “money” that developers paid to use the network—was called Ether. (These terms would quickly become confused, and today “Ethereum” is commonly used for both the network and the unit of value.) Ethereum was a brilliant innovation, because it allowed for a set of blockchain development standards, specialized skills, and a faster time to market. It was almost too successful because it made it easy for anyone to create blockchain-based units of value—also called tokens—that could be bought and sold by digital traders. In a sense, it made it even easier for people to “print money.”

History will remember Buterin, along with Satoshi, as one of the founding fathers of blockchain. Today, Ethereum is the second-largest blockchain project behind bitcoin, and it serves as a terrific case study for the building blocks of a successful blockchain project.

Decentralized Ledger Technology: The Beating Heart of Blockchain

Let’s return to our accounting ledger, in which Alice has now transferred one unit of Ethereum to Bob (Figure 2-1).

Figure 2-1. Alice transfers one ETH to Bob, as recorded in an accounting ledger

First imagine that we record this information into a local Excel spreadsheet. It’s now stored on one copy, one computer, as illustrated in Figure 2-2.

Figure 2-2. Alice transfers one ETH to Bob, as recorded in an Excel sheet

Next, imagine that we copy the information out of Excel into a Google Sheet: it’s now shared across hundreds of network nodes, across a cloud computing cluster, as shown in Figure 2-3. Compare the Excel file (one copy, one computer) to the Google Sheet (one copy, many computers).

Figure 2-3. Alice transfers one ETH to Bob, as recorded in a Google sheet

Blockchain takes it one step further: many copies, many computers, as demonstrated in Figure 2-4.

Figure 2-4. Alice transfers one ETH to Bob, as recorded on a blockchain

Look again at Figures 2-3 and 2-4 to engrave in your mind how decentralized ledger technology (DLT) is different from cloud computing. (Even though a Google Sheet is spread across multiple servers, it’s still centralized, since Google owns the servers.)

Decentralized Ledger Technology: The beating heart of blockchain. It allows us to keep all the transactions synchronized, across a distributed network of computers.

Blockchain is still “logically centralized,” in that there is only one ledger. However, it’s “organizationally decentralized” in that the ledger is not stored in any one central location. Rather, identical copies exist on every node.

Before blockchain, this did not exist. We’ve had client-server technology for 30 years, but decentralized ledger technology is something new. DLT is the beating heart of blockchain.

The remarkable thing about DLT is that we can keep all these distributed copies “synchronized,” anywhere in the world, while making multiple transactions per second. (Think about how difficult it is to just schedule lunch with friends.)

What’s more, we synchronize all of these copies in a way that is trusted, timestamped, and auditable. Let’s unpack each of these terms.

The decentralized ledger is trusted because it was arrived at through consensus (more on this shortly), with no central party having the authority to alter the data. A centralized Google Sheet could be altered by Google, but a decentralized ledger can’t be altered by a central company or institution. (Like the internet, no single organization “owns” it.)

The decentralized ledger is timestamped by creating “blocks”—a single record of data, like an entry on our accounting ledger—that ensure the proper sequence of transactions. Noting the time a transaction was made keeps the system safe and secure: we can’t create a “copy” of Ethereum that we’ve given to someone else.

The decentralized ledger is auditable because it is transparent: like a Google Sheet, we can all look back in time and see the complete sequence of transactions. Unlike cash, which is truly anonymous, a digital ledger leaves a trail whenever we make a transaction. The parties can still be anonymous, but their transaction is broadcast in broad daylight.3

That said, is DLT right for you? For most enterprise technology managers, a shared centralized database is a better solution: it’s faster, cheaper, and easier to deploy. Blockchain technology is better when you need to share “money” (or units of value) across a global network of participants: in other words, when you need to share the wealth.

Nodes and Miners

Ethereum—like the entire blockchain market—was going insane.

Because people could create their own tokens on top of Ethereum (the platform), the price of Ethereum (the altcoin) began to skyrocket. At the beginning of 2017, a single Ethereum was $10; a year later, that same Ethereum was $1,000.

As the price shot into the ether, so did the number of miners (people contributing their computers to the network). This in turn grew network capacity, so even more projects could launch on Ethereum, making even more money for the Ethereum ecosystem.

In other words, the increasing price radically increased the number of nodes as more people joined the network. These nodes served a few key roles:

Maintaining copies of the ledger

Like teens sharing a Metallica album on Napster, many nodes host the ledger, constantly keeping them synchronized. Because the ledger can become quite large over time, some nodes host only a part of the ledger, using a technique known as sharding.

Validating transactions

Through the process of consensus (coming up next), the nodes are constantly coming to “agreement” on which transactions are valid, then recording valid transactions on the blockchain (i.e., writing a timestamped block of data to the distributed ledger).

Mining

Broadly speaking, “miners” are dedicated computers that use specialized hardware and software to run a blockchain network, receiving a reward in the form of bitcoin, altcoins, or tokens. In other words, users set up a “mining rig”—that is, a custom-built computer —and earn rewards for hosting a node in the network.

Sharding: An unfortunate blockchain term that means splitting a large database into smaller subsets (like breaking glass into shards).

For the enterprise technology manager, this concept of “nodes” and “miners” is critical. At their outset, all blockchains face a chicken-or-egg problem: without users, you don’t have a blockchain, but without a blockchain, you can’t attract users. The blockchain isn’t centralized: you can’t just spin up a cluster of servers. It’s decentralized: you’ve got to convince users to join.

So how do you “kickstart” a blockchain? You mine it.

Mining: Broadly speaking, the process of earning rewards (usually in the form of “coins” or “tokens”) by contributing computing power to the network.

Users want to see some reward for participating in your blockchain: again, the perception of value. The term mining is now used generically to mean any reward for hosting a node in the network.

This is another reason we think of blockchain as the Internet of Money: your “money” (i.e., your units of value, your “coins” or “tokens”) is typically used to reward your miners for participating in the network.

This is how we solve the chicken-or-egg problem: we pay off the chickens.

The Consensus Algorithm

We reject: kings, presidents, and voting. We believe in: rough consensus and running code.

Dave Clark, Internet Engineering Task Force4

We’ve established that blockchain uses a distributed ledger (a massive shared database), which is maintained through nodes and miners (a global network), who are rewarded with tokens (your in-game currency). But with transactions simultaneously happening all over the globe, how do we keep all this synchronized? We call this consensus.

Consensus (also called the consensus algorithm or consensus protocol) is the process whereby all the nodes reach agreement on a transaction. It’s important to note here: We don’t mean that humans are manually agreeing on each transaction. Quite the opposite: as Dave Clark points out above, consensus is not voting. Consensus is happening behind the scenes, in code: machines agreeing with machines.

Consensus currently comes in several different flavors, which we cover next.

Consensus protocol: The algorithm that computers use to automatically “agree” with one another.

Proof of Work

Proof of Work (PoW) is the original consensus protocol used by bitcoin. In this method, computer nodes solve increasingly complex mathematical problems for the right to validate transactions (i.e., approve them to be written as a new “block” of data). As the complexity increases, so does the processing power required to solve those problems.

The computers providing that processing power are not only expensive to build, but expensive to run: computing power requires electrical power. The idea is that this challenging mathematical “work” further justifies the value of the bitcoin, because it uses real processing power and real electricity.

In fact, a common criticism of bitcoin is that it uses too much electricity. According to The Economist, the total energy consumption used by the bitcoin network alone could power Ireland!5 This massive energy draw is the reason that blockchain developers are experimenting with alternative consensus mechanisms.

In the early days, anyone with a home computer could mine bitcoin. Then it specialized into custom mining rigs, then warehouses of mining rigs, then enormous server farms located near cheap energy sources. As it became more competitive for individual miners to make any money, they began joining together in huge profit-sharing collectives, or “mining pools.” Many of these pools further consolidated into companies that now control large chunks of the bitcoin network.

Consensus is a funny thing. As power consolidates among competing mining companies, we end up with something like an oligopoly, with a handful of enormous players controlling most of the mining power: exactly the problem that a decentralized network is trying to solve.

We call this the Consensus Paradox: a decentralized consensus algorithm tends to become more centralized as it becomes more widely adopted.

Consensus Paradox: As a decentralized consensus mechanism becomes more widely adopted, it tends to become more centralized.


Proof of Stake

The most common alternative to Proof of Work is Proof of Stake (PoS), in which nodes have mining power proportional to the number of tokens they own. For example, in Ethereum 2.0,6 which is built on PoS, someone who owned 1% of all the Ethereum could validate (or approve) a maximum of 1% of all the transactions.

Proof of Stake (PoS): An unfortunate acronym, where users have to “prove” their “stake” in the network in order to validate (or “mine”) new tokens.

Proof of Stake’s huge advantage is that it uses far less electricity: rather than everyone “competing” for rewards, we just distribute the rewards proportionally to who owns the tokens.

But here again we run into the Consensus Paradox: under this scheme, the rich get richer, while the poor get poorer. Like the Monopoly player who’s developed hotels on the most valuable properties, the wealthiest token holders get proportionally more of the benefits.

PoS does, however, create an enormous incentive for players to ensure the integrity of the system: the more blockchain tokens you own in a PoS system, the more you want that blockchain to succeed. Nobody wants the Monopoly game to end early if they’re winning.

Experimental consensus algorithms

The Consensus Paradox is one of the most interesting problems in blockchain, so there are a host of new consensus algorithms in the works, such as Delegated Proof of Stake, Tangle, and Hashgraph. It’s a difficult problem—how do you get thousands of independent nodes to continually stay in agreement? And each solution has its own strengths and weaknesses.

As you can see, blockchain presents challenges that are both technical and financial. Ethereum got it right on both fronts: a good consensus protocol (technical), with built-in incentives for nodes and miners (financial).

We’re seeing that blockchain—the Internet of Money—has many moving parts. As an enterprise technology leader, you’re not just building a technological system, you’re building an economic system (Figure 2-5).

Figure 2-5. Blockchain sits at the intersection of technology and economics. Let’s call it “techonomics”

Indeed, it’s helpful to think of blockchain as a new discipline that sits at the intersection of money and technology. This requires new skills. A traditional network admin will not understand how to create economic incentives, just as a traditional economist will not be able to understand consensus protocols.

Instead, we encourage enterprise blockchain leaders to begin training tokenomists, a new job position that understands both economic principles as well as blockchain technology. In the job market of the future, tokenomists—both literally and figuratively—are going to mint money.

Tokenomists: A new job role that combines economic theory with blockchain technology. Starting salary is $200,000 annually (but you can pay it in tokens).

1 Buterin, Vitalik. “Ethereum White Paper: A Next Generation Smart Contract and Decentralized Application Platform.” Ethereum.org, 2013. http://blockchainlab.com/pdf/Ethereum_white_paper-a_next_generation_smart_contract_and_decentralized_application_platform-vitalik-buterin.pdf.

2 Rugbyowl. “So Where Did the Name Ethereum Come from?” Ethereum Community Forum, March 20, 2014. https://forum.ethereum.org/discussion/655/so-where-did-the-name-ethereum-come-from.

3 “Is Cryptocurrency Money Laundering a Real Threat?” AMLRightSource.com. AML RightSource, January 15, 2019. https://amlrightsource.com/posts/are-cryptocurrencies-a-real-threat-to-anti-money-laundering-monitoring/.

4 Russell, A.l. “‘Rough Consensus and Running Code’ and the Internet-OSI Standards War.” IEEE Annals of the History of Computing 28(no. 3); 2006: 48–61. https://doi.org/10.1109/mahc.2006.42.

5 “Why Bitcoin Uses so Much Energy.” The Economist. The Economist Newspaper, July 9, 2018. https://www.economist.com/the-economist-explains/2018/07/09/why-bitcoin-uses-so-much-energy.

6 “Ethereum 2.0 Specs.” GitHub, 3 Sept. 2019, github.com/ethereum/eth2.0-specs.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset