GC Alpha — Project Oxide III

GeniusTeam
5 min readApr 19, 2023

--

Part 3. A look at Rollup DApps.

Hello Geniuses, and welcome to the final Project Oxide update! In our previous article we took a dive into the product side of optimistic rollups, and what architectures are possible when building out an L2 project on Tezos. If you missed that article, find it here.

Today, we’re going to take a look at the end-to-end user experience of interacting with an enshrined rollup on Tezos. We want to use this article to prepare users for our first rollup DApp, coming to testnet soon.

Rollup DApp Anatomy

How does it work?

When interacting with a Layer 2 DApp, the simple goal is for the user to sign messages and send them to the smart rollup. When compared to normal smart contract calls, L2 messaging is more flexible because there are multiple ways to send a message to a Tezos rollup.

This messaging flexibility is the killer feature that allows us to build games with instant response, and finally break free of 15 second wait times.

We will dive into the pros & cons of different messaging styles later in the article. First and most importantly, you’ll need a rollup address!

Rollup Addresses

tz1 or tz4, dealers choice!

You may have heard some noise around tz4 rollup addresses in the past few months on Tezos. The tz4 address has certain cryptographic qualities that make it a good fit for use on a rollup, but this is not the only type of address that can be used on Tezos rollups.

Depending on the project architecture, a rollup DApp can still use a normal tz1 address and work fine. In our initial Custom Execution rollups, we will be relying on tz1 addresses. Onboarding with a tz1 addresses is much simpler because of the availability of signing infrastructure that exists for them.

The tz4 address is better for rollups that use a sidechain, like the upcoming EVM rollup. Users on the EVM rollup are going to need the ability to batch multiple ether transfers or Solidity contract calls in one message. The tz4 address makes it simple & cheap for the rollup node to verify the BLS signature for the batched message.

We aren’t going to dive deeper into the cryptographic magic behind these addresses. Just expect to use tz1 addresses in the short-term, and tz4 addresses on future rollups that contain sidechains (EVM, GeniusChain, etc). Let’s now focus on what these addresses actually do.

Layer 2 Messaging

It’s time to sign & send messages to the rollup.

At this point in the journey, it’s time for you to use your Tezos wallet to sign messages and send them to the rollup. Messages can be posted directly to the Tezos L1 or, more commonly, sent to a rollup node for batched message posting. By using a rollup node, we unlock a very important feature of optimistic rollups: Lookahead Messaging.

Lookahead Messaging means that the DApp can provide an instant response once the message is signed and delivered to the rollup node. The DApp essentially looks ahead at the queued messages and considers them to be valid, rather than waiting 15 seconds for the messages to hit the L1 chain.

The messages will eventually get posted to L1, but they sit in an offchain queue on the rollup node until the whole message batch is posted to L1. In this case, the DApp will read the messages in its queue and optimistically assume that they will go through. The messages have already been signed, so from the optimistic rollup perspective: it’s as good as onchain.

Lookahead Messaging is an important part of adding instant-play to our Layer 2 games.

Without lookahead messaging support, users will have to wait until your message hits the L1. This will bottleneck a DApp with 15 second update times, but users still benefit from increased TPS and the ability to execute complex runtime environments on top of Tezos, like EVM.

In the EVM example, being able to offer full Solidity support on Tezos is still massive even without lookahead messaging.

From L2 to L1.

When we get into Lookahead Messaging, there is a larger conversation about (de)centralized sequencers and who decides which transactions came first. There are many paths to implementing decentralized sequencers, and we will be researching all options on how to add this technology to our future GeniusChain.

With that said, we will follow the classic route and use a centralized sequencer to keep our initial focus on delivering instant-play DApps. In this initial stage, users will be required to use our sequencer to benefit from our instant-play features.

Our DApps will still be fully available to use via direct L1 messaging; this provides a balance for those who don’t want to use our sequencer. The only drawback with direct L1 messaging is the loss of instant-play.

Play & Enjoy!

Sign, send, repeat.

At this point, the DApp operator should have everything they need to deliver a fun experience to the user. As you can see, interacting with L2 DApps on Tezos will mostly involve message signing and data retrieval from the rollup node.

One major use-case for Layer 2 is gaming, and we’re going to show off Tezos L2 technology with our upcoming game: L2 Video Poker. Our rollup kernel is already written and deployed on testnet; work is underway on UI.

We are going to show the Tezos ecosystem the power of instant-play.

Today's update should give you more knowledge around how DApp interactions will feel on Tezos Layer 2.

This is the last Project Oxide update, L2 Video Poker will be the subject of our next article. Get ready!

GC

--

--