Improving The Utility Of Statechains This proposal would greatly improve the utility of a statechain by loosening the strict liquidity dynamics of how they work. Whenever someone would be willing to accept a statechain but the denomination doesn’t match the payment, the sender can simply open a Lightning channel between them instead and wait until they need to spend the rest of the funds (or wind up receiving what they sent back) to finalize a transfer of the entire statechain balance. Such a possibility not only increases the utility of a statechain, but also increases the utility of the Lightning Network if properly supported.
Channel rebalancing is a necessity for nodes on the network, both routing nodes as well as edge nodes simply sending and receiving transactions. When funds flow completely to one side of a channel, it makes the channel useless for passing payments in one direction (if all of the money is on your side, then you can’t receive payments; if it’s on the other side, then you can’t send payments). This necessitates shuffling money from one channel to another, which also contributes to unbalancing the channels along the way to rebalance your own. Eventually this dynamic gets to a point where things must actually be rebalanced by swapping funds between Lightning and the base layer on-chain.
Statechains allow liquidity to be moved around with the same freedom provided by doing so on-chain, without needing to create the on-chain footprint or pay fees for it. Say you have a depleted channel, with all of the liquidity on the other side leaving you, no spending capacity and you also have a statechain. That statechain can be freely transferred to anyone who will accept it, and it can even have a Lightning channel on top of it if you aren’t sending the entire value, and it can be used to rebalance funds in your regular channel on your side.
This allows for much more efficiency in terms of how many channels you have to route through in order to rebalance your channel (remember, you are contributing to shifting the balances of every other channel you route through), in the best case literally sending it directly to the same peer that you have the channel that you are rebalancing open with. If you wish to close a channel with one peer and open it with another, you can even rebalance things so you have all of the balance of the channel and move it entirely off-chain to the new peer if it is built on top of a statechain.
The Future Of Statechains And Lightning Discussing their plans going forward, Nicolas Gregory from Commerceblock said: “Our goal is to establish a standardized approach for combining statechains and Lightning technology in order to facilitate off-chain balancing of Lightning channels through the use of state channels. This specification will serve as the foundation for achieving this objective.”
From the very beginning, statechains were always proposed to interact with Lightning in order to solve the issue of using them by themselves: that you must transfer the entire value of the whole UTXO. They also provide a degree of flexibility to Lightning that it does not have on its own in terms of how liquidity is managed and transferred around the network.
Now that Lightning is at a healthy stage in its early growth, and a concrete implementation of statechains has existed for over a year, it’s time to start considering how these two technologies can interact together. Lightning as a network is a system for atomically-escrowing transfers between two parties that are not directly connected on the network graph. How each connection on that graph works, strictly speaking, should not matter to senders and receivers of payments, as long as it works.
Statechains and Lightning channels both have a lot to offer each other in terms of benefits, all that needs to be done is to work out standardizing the two interacting with each other.
This is a guest post by Shinobi. Opinions expressed are entirely their own and do not necessarily reflect those of BTC Inc or Bitcoin Magazine.