DOOM On Hydra Achieved Record TPS

At Rare Evo, attendees had the unique opportunity to play DOOM on Hydra. It was possible not only locally but also globally. The demand for this unusual experience was so high that the capacity had to be increased from 65 to 138 Hydra Heads. Over the three-day event, several tens of millions of transactions were processed, with the highest TPS recorded at 7,182, though it could potentially be even higher. The crypto community is now buzzing about Hydra’s potential and future. John Woods, CTO of Algorand, tweeted, ‘Doom running on Hydra is one of the coolest things I’ve ever seen. Literally every frame is a transaction.’. Charles Hoskinson suggests establishing a Lightning Labs-like company for Hydra.

DOOM on Hydra

DOOM runs at 35 frames per second. The team modified the game engine to generate a transaction after each frame, which was then processed by a smart contract. At the start of the game, a new UTxO with the initial game state was created. Players could spend UTxO to update the game state, with input provided by the redeemer.

The validator ensures that the player’s position does not change by more than 143 units from frame to frame, which is the maximum player speed. Due to time constraints, validating multiple game events was not possible.

Each Hydra Head can process several hundred TPS and handle transactions from multiple games simultaneously. Initially, 65 Hydra Heads were opened, but due to high demand, some players had to wait for a spot to become available. To accommodate this, the team increased the number of Heads to 138. When a new player wanted to start playing, he was assigned to the least busy Hydra Heads. This allowed several hundred players to play DOOM in parallel, with each player generating 35 transactions per second. The highest TPS recorded was 7,182.

Several tens of millions of transactions were processed, amounting to several gigabytes of data. Fortunately, since Hydra operates as a second layer, these transactions were handled off-chain. This means that the massive amount of data did not need to be stored on the Cardano blockchain.

Hydra scales horizontally, meaning that as demand increases, new Hydra Heads can be opened to boost overall throughput. This makes the number of players theoretically unlimited.

In contrast, blockchain does not scale as easily. Adding more validation nodes to the network does not increase throughput, as it is typically constrained by block size and block production rate. Adding more nodes can even decrease the quality of block production, as it places higher demands on the consensus mechanism.

The Rare Evo event was great marketing for Hydra as well as for Cardano. The entire crypto community was buzzing about DOOM on Hydra over the weekend. People have started comparing Hydra to the Lightning Network, a similar solution in the Bitcoin ecosystem. Although both networks are based on state channels, they differ in many ways.

Charles Hoskinson was so thrilled by the experience that he plans to host a $100,000 tournament at the Cardano Summit. A small team of developers worked on the demo for about two months and promised to make improvements or offer new surprises by the time of the summit.

Charles is also considering starting an initiative similar to Lightning Labs for Hydra. Lightning Labs, backed by major venture capital firms, is the leading company developing the Lightning Network. Charles envisions a similar entity for Hydra to accelerate development and introduce more features.

The Future of Hydra

Unlike the Lightning Network, Hydra features isomorphic channels, meaning it uses the same infrastructure as Cardano, including data formats, transactions, and script execution. Essentially, Hydra can perform the same functions as Cardano with the same level of security. The same libraries that teams use to build on Cardano can also be used when building applications for Hydra. The primary difference lies in the consensus mechanism: Hydra’s consensus is based on participants agreeing on a new snapshot.

While the Lightning Network allows only two participants to open a channel and exchange Satoshis, Hydra enables roughly a dozen participants to open a Hydra Head and utilize all Cardano features. This includes sending Cardano native assets (including stablecoins) and executing scripts, paving the way for DeFi on Hydra.

In the Lightning Network, users must open a new channel for each interaction with different users or rely on routing, which incurs small transaction fees. Currently, routing between Hydra Heads is not possible, but the team plans to implement this feature. Users can now exit a Hydra Head without closing it, thanks to a feature called incremental decommit. Incremental commit, which allows entry into an already open Hydra Head, is also in development.

This functionality is particularly interesting for launching DeFi services on Hydra, where participants can enter or exit as needed.

Building a DeFi service on Hydra can be challenging, as it may require using multiple Hydra Heads, which can divide users and capital. The ability to connect users and capital will depend on the characteristics of the protocol that enable the interconnection of Heads. Alternatively, teams can design a solution specifically tailored for Hydra to address these challenges.

This marks a significant difference from the Lightning Network, which does not inherit anything from the Bitcoin protocol. The Lightning Network is essentially a new network with its data model and transactions, and it does not support sending assets other than BTC or executing smart contracts. While Bitcoin allows minting and sending tokens, it requires external protocols for these functionalities.

Hydra’s main strength is its versatility, as it supports more than just sending a single asset and can connect multiple users. For groups looking to exchange a large volume of transactions with each other for free, Hydra is the perfect solution.

Hydra and Other Scalability Solutions

Hydra is an L2 scalability solution.

Some influencers argue that L2s are not an ideal scalability solution because multiple dominant L2s within a single ecosystem can be incompatible with each other. This is evident in the Ethereum ecosystem, where it leads to fragmentation of users and capital. Additionally, from a UX perspective, it is inconvenient as users must explicitly enter an L2 and decide which assets and how much to transfer. Furthermore, many of the leading L2s in the Ethereum ecosystem are centralized.

L1 scalability offers several advantages, such as not fragmenting users or capital. Users only need one wallet and one network, ensuring direct connections to all network participants.

However, L1 scaling has its drawbacks. All transactions are permanently stored on the blockchain and are public, which is unsuitable for many use cases, including payments that require privacy. While blockchain might suffice for trading memes or airdrops, it is unlikely to replace current global payment networks. Currently, even Solana or blockchains with sharding are not the best candidates.

A network processing 1000 TPS continuously would generate several tens of gigabytes of data daily, making it impractical for users to download all this data to their local computers. Although solutions like data sharding across nodes, data pruning, or storing references to data (similar to Ouroboros Leios) are possible, they have not yet been implemented.

Keeping all payments, including micro-payments, on the blockchain forever is impractical. It is more efficient to process payments off-chain in L2 solutions like Hydra and only handle final settlements on L1. Transactions in L2s are faster, cheaper, and more efficient, and achieving privacy is easier.

A blockchain that publicly stores all transactions is unlikely to be adopted as a global payment network.

Hydra allows each user to run their own Hydra node, protecting their assets if needed. In contrast, L2s in the Ethereum ecosystem do not let users participate in consensus and approve transactions, which is possible in a Hydra Head.

Additionally, in Lightning networks, the ratio of non-custodial to custodial users is 1:8. It will be interesting to see what the ratio will be in Hydra. As soon as the light Cardano client is delivered, we can start thinking about the light node for Hydra. In theory, one mobile app would be enough for a trustless payment system.

If Bitcoin focused solely on opening LN channels for new users, it could onboard 200 million people to LN in a year. While this is a significant number and could be seen as a success, the assumption is unrealistic. If opening LN channels occupied only 20% of the block space on average, it would only onboard 40 million people per year. The issue is that if blocks were full and fees were high, users might end up paying higher transaction fees than the amount of Satoshis they want to transfer to LN.

The same logic applies to Cardano and Hydra (although Cardano does not use a fee market). Therefore, for Hydra to onboard hundreds of millions of users, implementing Ouroboros Leios is essential.

Conclusion

Currently, it’s challenging to predict whether the decentralized global financial infrastructure will rely on L2s or a sharded blockchain capable of handling tens of thousands of TPS, like Hydra. L2s have an edge due to their privacy features and the ability to avoid storing vast amounts of data. In Web3, users will engage in numerous swaps, not just value transfers.

For instance, buying tokenized tickets places an unnecessary storage burden on the blockchain. However, with L2 solutions like Hydra, tickets can be easily swapped for stablecoins, used at entry checks, and then all off-chain transactions can be forgotten. Many similar use cases require smart contracts. The future global infrastructure will encompass not just payments but also P2P operations like swaps, enhancing security, and reliability, and eliminating costly intermediaries.

Hydra is now ready for real-world applications. It’s time for teams to start building on Hydra.

2 Likes