Blockchain offers a wide range of killer applications for payments that don’t support global adoption due to their limited capacity. Block size shortage, high fees, and time-consuming confirmation have caused the scalability issue that is currently slowing down the network.
There is no shortage of materials covering this aspect of blockchain technology in terms of scalability and solutions. Therefore, we have engaged our experts to share their knowledge on that. Read and learn.
In comparison with Ethereum, the Bitcoin network is able to conduct far fewer transactions: more precisely, one transaction per ten minutes, which causes huge lines of transactions waiting for users to confirm them. At the moment, the Ethereum network can conduct one block in twenty seconds. This seems like a negligible amount of time; however, it is still not enough for adoption as an everyday payment platform. In the case of wide adoption, the network will need to cope with hundreds of thousands of transactions per second. Moreover, to adopt everyday payments on the blockchain, there are several additional aspects that need to be fixed, such as transaction cost and confirmation time.
When a node sends a transaction to a pool, the system defines a minimum gas (a transaction cost) that the user has to pay for the transaction to be confirmed. Also, the node may increase gas in order to get faster confirmation. Transactions with a higher gas fee are at the top of the waiting list. So eventually, for nodes that can’t afford to pay more gas, it becomes a time issue.
The capacity of any blockchain network is currently limited because before nodes can confirm transactions in a block, they need to mine it by solving a mathematical problem. Only after one of the nodes has managed to solve the puzzle can the community confirm transactions in this block. As soon as it is validated, the transaction becomes a part of the distributed ledger. All of these actions take time, and sometimes, the route from transaction to confirmation can take several days. Of course, the confirmation time depends on gas. No miner will process a block if its gas is lower than average; gas is, literally, the miner’s profit.
There are numerous options for users to choose from, starting with soft forks like SegWit and hard forks like SegWit2z. These are followed by the Lightning Network, Plasma, Plasma Cash, and the Raiden Network. Here, Applicature can provide a full picture of what each solution offers to the market
SegWit and SegWit2x
The Segregated Witness solution on Bitcoin came along in 2016, when the crypto community was discussing the scalability issue and the opportunities that increased block size would bring. SegWit offered to move the signature to the end of the transaction code, which would significantly reduce the size of the transaction and reload the network. The block size with SegWit increases up to 2MB, while the hard fork SegWit2x suggested expanding a block up to 4MB.
However, in the end, none of the solutions were adopted by the community.
All scalability solutions are aimed at reloading the list of transactions waiting for confirmation, and this is the case with Bitcoin Lightning. This is an off-chain network that allows the creation of direct-payment channels between nodes for cheap, fast transactions.
In order to open a payment channel between two nodes, they contribute an even amount of money to a wallet with a multi-signature. This sum will define the maximum sum allowed for transmission within this channel. The biggest advantages of the Lightning Network are:
- the absence of a transaction fee
- no need for the network to confirm transactions
Therefore, transactions are free and immediate. Moreover, when the nodes decide to close their channel, they can get their money back.
The only case requiring a fee would be building a network inside of Bitcoin Lightning. When there is a direct payment channel opened between A and B, and B also has a channel with C, if A wants to pay C, they don’t have to open a new channel. A can ask B to transmit money to C for a certain fee.
Security on the network is ensured by the fact that there is no opportunity to exit the channel without mutual agreement. Therefore, no participant can exit and/or steal a contribution without the other’s party confirmation.
None of the transactions conducted between nodes on Lightning are shared to the blockchain except for the opening transactions that the nodes create when opening their channel.
The Bitcoin Lightning Network is the perfect solution for parties that have a financial relationship, need to pay each other often, and require cheap and on-time transactions. However, the Lightning Network operates only on the Bitcoin Blockchain.
The Bitcoin network is not the only one trying to cope with the scalability issue. Ethereum can’t match payment systems as Visa, Mastercard, and Paypal, either. However, it is accompanied by an analogy of the Lightning Network: Plasma.
Unlike Bitcoin, the scale of the Ethereum network can be improved by turning to Proof-of-Stake Casper and sharding (these are not the only variants), which had to be implemented about a year ago.
On November 9, Vitalik Buterin and one of the key developers of the Lightning Network published the white paper for Plasma project, which, in fact, is a Lightning algorithm implementation on Ethereum.
Ethereum is a network in which smart contracts are the “lawyers” regulating the financial relationships between nodes. Similar to the Lightning Network, where input is used to open the channel that determines the sum that can be transmitted within the channel, in Plasma, the transaction sum is controlled by a smart contract.
In addition, in the Lightning Network, privacy is provided by the inability to leave the channel without the other side’s approval. Meanwhile, in Plasma, a node can exit the channel at any time without the need for approval, as everything is controlled by a smart contract.
Plasma allows the sending of tokens quickly and securely without having to wait for transaction verification. The technology refers to off-chain channels regulated by Ethereum smart contracts (Balance blockchain model) not maintained by the Blockchain network. Instead, Bitcoin operates with a UTXO blockchain model (Unspent Transaction Output).
Blockchain Models: UTXO vs. Balance
Apart from the fact that UTXO and Balance are used on two different blockchains, they represent two different approaches to money transmission.
The UTXO model principle is quite complicated. The number of Bitcoins that a wallet contains is considered a UTXO. In order to send one Bitcoin, the user will send his/her UTXO, and the receiver will send the change back. To make everything clear, let’s look at an example of a UTXO transaction:
- Node A has three Bitcoins in their wallet, and wants to send one to node B.
- Node A unlocks the UTXO and inputs the whole thing into the transaction.
- When node B gets the transaction, his or her wallet is supplemented by one Bitcoin, and B sends two Bitcoins back as change.
On the other hand, there is an account/balance model on Ethereum that doesn’t require staking a balance in order to send a transaction. The balance model is designed to make sure that A’s balance is equal to or greater than the money he/she wants to send to the node B.
If node A has three Bitcoins and wants to send one to B, the system will subtract one BTC from A’s wallet and replenish B’s wallet with BTC.
The UTXO and Balance blockchain models can be associated with paying in cash and by credit card. When you buy bread and give a five-dollar bill to the cashier for bread that costs three dollars, you get two dollars’ change. This is analogous to the UTXO model.
If you pay for a taxi with your credit card, the system deducts the necessary sum of money from your wallet. The only requirement is to have an equal amount of money to the taxi price or more on your card: the Account/Balance model.
Currently, Ethereum’s network size is over 400 GB, and it is constantly growing. This causes scalability issues due to the fact that the ledger is distributed.
When creating a sidechain on Ethereum based on the Plasma Cash algorithm, you create a non-fungible token with its value in Ether or ERC20 tokens. The transactions within the sidechain shouldn’t overtake the value of your token. A smart contract controls whether everything goes according to the agreed-upon consensus.
The main difference between Plasma and Plasma Cash is that in Plasma, users need to download each block, which causes huge scalability concerns. To fixing this, Vitalik Buterin and the co-founder of the Lightning Network, Joseph Poon, have presented Plasma Cash, which only requires keeping track of the blocks with the coins that the user is interested in.
While Plasma is profitable when conducting frequent micro-payments, Plasma Cash is used for business that gets money from inside while the nodes need to send transactions within the sidechain. An analogy to the Plasma Cash principle of work is a casino: you buy chips (tokens) to play, you may win and get more chips, or you may lose. When you want to stop playing (exit the sidechain), you change your chips back into money (Ether).
Each of the above describes a project that has somehow figured out the scalability issue of the Ethereum network. Plasma offers the opening of direct payment channels and conducts fast, cheap transactions; however, each node has to download every block. In Plasma Cash, participants in the sidechain don’t have to download each block. Instead, they track the blocks they are interested in. As a result, transactions are fast and cheap, and the ledger is not weighty.
While Plasma Cash involves smart contracts to control token transactions within the network, the Raiden Network works on a smart contract that allows sidechains to process public smart contracts due to the overburdening of the Ethereum public blockchain. The sidechain has enough computational power to process a public smart contract, and sends the value back to the public blockchain.
Through borrowing computational power from sidechains, the list of blocks waiting for confirmation on the public blockchain is shortened. This concept is called sharding. In other words, any subnetwork on Ethereum can borrow computational power from another subnetwork for a certain fee.
The Raiden Network Under the Hood
Because Raiden doesn’t have a white paper for reference yet, Applicature will share a complete guide on how Raiden works and the benefits it offers.
Raiden’s goal is to bend blockchain consensus. This is possible due to leveraging the network of payment channels, which allows secure transfer of ERC20 tokens off-chain without the need to register each transaction on the public blockchain.
State Channel Technology
The Raiden network is an up-and-coming scalability solution based on state channel technology. To gain a deeper understanding of what Raiden really does, we’ll follow up with a state channel explanation.
A state channel is a connection between two nodes that allows them to send transactions near-instantly and free of charge. The only input the nodes contribute is escrow, which opens the channel and is under a smart contract control. However, the most important peculiarity is that transactions occur off-chain, and nodes don’t have to report every action to the public blockchain (in our case, Ethereum).
How Does the Payment Channel Work?
The payment channel in Raiden is an agreement between two nodes in which the sender sets up a deposit of tokens on the blockchain for the receiver. Payments take place off-chain through privately-exchanged messages which digitally transfer the value. A smart contract validates and signs the transaction and settles the claims.
Channels can also form a network which enables payments between two nodes that don’t have a direct payment channel. Several payments can happen concurrently without the need for global consensus on each transfer. Money transactions in Raiden are fast and do not cost any gas. This is possible due to the off-chain implementation.
Nodes that open a payment channel between each other create escrow that defines the capacity of the channel. If the capacity is, for example, five BTC, node A can only send to B a maximum of five Bitcoins. However, if the channel is bi-directional, it can be rebalanced.
Raiden Network and Smart Contracts
Let’s imagine that there are two sidechains that want to become business partners, and share information or send transactions to each other. Obviously, they can build a partnership between two nodes on the public blockchain; however, each transaction will take time and fees. The way out is to build sidechains and take an advantage of instant payments. Moreover, with the help of Raiden, these sidechains can financially interact without the need to report to the public blockchain.
One of the main advantages of the Raiden network is that sidechains can transact in both ETH and ERC20 tokens. No matter what the sidechains want to send, however, the receiving party won’t accept it without confirmation from a native smart contract. The sender calls the function “call” to get the confirmation, and when both sidechains support one smart contract to take the advantage of all the benefits of Raiden.
The Raiden Network doesn’t have a white paper yet, but there is a roadmap on its website.
The Ethereum blockchain is unlikely to become a globally-adopted payment system for cryptocurrencies unless its transactions become faster, cheaper, and require less computational power. The Raiden network offers a solution to each issue mentioned above, and has even more potential in its perspective.
So far, the net has adopted the µRaiden (micro Raiden) network for fast, many-to-one, cheap ERC20-token transactions. The developers of the project are also working on other technologies:
- Channel opening, closing, and settlement. In Raiden, users are able to connect with other users even if they don’t have a direct payment channel through them. Transactions like these will remain near-instant, and will require a minimum fee.
- REST API. Developers will also be able to build dApps on top of the Raiden Network.
- Recoverability. In case a node fails, this feature protects the channel from data loss.
- Raiden Red Eyes. The release of Red Eyes on the Mainnet will provide a bug-fixing system along with user feedback. Safety limits will also be implemented: 250ETH of the maximum value for escrow mentioned in the smart contract, and WETH, the maximum deposit for the node/direction, stands on 0,5ETH.
Here are some functions the Raiden development team is planning to implement in the future:
- Channel withdraw. The users who created a payment channel will be able to withdraw funds without the need for closure.
- Atomic token swaps. This function enables decentralized-exchange implementation based on state channels.
You can find a full list of functions that are going to be added to the Raiden network/system on its official website.
Raiden Network Token
Unlike Plasma (works with Eth) and the Lightning Network (works with BTC), the Raiden project has a native currency (RDN), even though it works with both ETH and ERC20 tokens.
The RDN token is already available for use by Ethereum nodes for micropayments on µRaiden. Initially, the total supply is 100,000,000,000 RDN tokens.
The latest update on Cryptolization shows that the total market for RDN token stands on $212,132,167,873 U.S.
According to Binance, the current price of Raiden Network tokens is $0.484789 U.S.
Raiden Network Advantages
Among other scaling solutions for blockchain, Raiden has a long list of features that businesses will find rather beneficial:
- Transaction time. While on-chain transactions stay in line for validation and users sometimes wait for days until somebody decides to mine the block, in an off-chain network, no transactions need validation. This refers to a direct channel that two nodes open and within which they sign an agreement (smart contract) that ensures that all actions are trustworthy.
- Transaction fees. Of course, a node can increase the gas he/she defines for the transaction in order to secure the verification time; however, this makes money transfer costly on the blockchain. Fortunately, this is not a dead end for blockchain as a payment system, owing to Vitalik Buterin and Joseph Poon, who took care of the fees issue with scaling solutions like Plasma, Plasma Cash, and Raiden. Now, in off-chain networks, users only contribute when opening a payment channel when the transaction charges no fee.
- Capacity. Taking the Ethereum and Bitcoin networks as an example, capacity is fixed. This differs from the Raiden Network, which grows in a linear fashion according to the number of users in the network.
- Privacy. Blockchain is, by default, a distributed ledger in which each node records all transactions ever conducted on the public blockchain. For businesses that store confidential data on the distributed ledger, this may become an issue in terms of privacy. That is why creating sidechains becomes a proposed remedy.
What Difficulties Does Raiden Face?
The blockchain is a young technology, and it is constantly growing and improving. However, each technology that offers a solution to one issue faces two more issues on its path. Let’s review the difficulties facing the Raiden Network:
- Locked-up tokens. Both participants in the payment channel should have a certain number of tokens in his/her wallet to create the channel. The system will lock these tokens until channel closure; otherwise, the nodes will not be able to open a direct payment channel. Furthermore, it becomes costly to open several direct payment channels, as the node will have to lock up additional tokens. On the other hand, there is no need to open several channels due to the ability of node A to send tokens to node C through node B (of course, paying a certain fee).
- Micropayments. Due to the deposit that nodes must contribute in order to open a channel, they limit themselves to have the maximum number of tokens to be transmitted within the channel. This leaves no choice but to conduct heavy transactions on the public blockchain.
Let’s say that node A opened a channel with node B, and they contributed one ETH each. This means that the channel capacity is two ETH. If the channel is unidirectional, node A can send B even a hundred transactions, but the total amount shouldn’t overtake the two ETH contributed. However, if the channel is bi-directional, A and B can rebalance each other, and send an infinity of transactions as long as the total assets of the transaction are less than or equal to the escrow.
The Ethereum community has been waiting for Raiden adoption on the blockchain since its release. It should wait no longer, as the Raiden development team will soon finish testing the technology. Moreover, there is already an available prototype of Raiden Network: µRaiden.
The confusing thing about Lightning, Plasma, Plasma Cash, and Raiden is how, exactly, they differ from each other. Let’s start with the fact that Lightning works on Bitcoin and allows the opening of direct payment channels while spending less time and money on transactions.
Both Plasma and Raiden are very similar to Lightning; however, Plasma only works with ETH, unlike Raiden, in which users may use ETH and ERC20 tokens.
Among other available scaling solutions, Raiden stands out with its sharding ability, which means that sidechains are able to send smart contracts for processing to another sidechain.
One more technology that solves Ethereum scalability and helps unload the network is Plasma Cash, which also works with both ETH and ERC20 tokens. This technology allows users to transfer tokens from the public blockchain to the sidechain, and send them within the sidechain for a great profit in terms of extremely low fees.
If your business needs to implement any of the above-mentioned technologies, please contact the Applicature team for additional information.