Layer 2 Interactions

This section explores how sequencer node interacts with Laïka's smart contracts. It focuses on functionalities crucial for sequencers to process and submit L2 transactions efficiently.


Communication with Smart Contracts

Sequencer node interacts with Laïka's smart contracts using a secure communication channel . Here's an overview of the interaction process:

  • Sequencer Client: Sequencer node connects to Laïka's L2 contracts.

  • Contract Interaction Methods: The sequencer client utilizes functions exposed by relevant L2 contracts (e.g., Sequencer contract, Fee contract). These functions allow sequencers to perform actions like:

    • Submitting batches of L2 transactions.

    • Withdrawing earned fees (subject to specific fee distribution mechanisms).

    • Interacting with dispute resolution mechanisms (if applicable).


L2 Transaction Processing

Sequencers play a vital role in facilitating L2 transactions on Laïka. Here's a breakdown of their workflow:

  1. Transaction Pool: The sequencer maintains a pool of L2 transactions submitted by users on the Laïka network.

  2. Transaction Validation: Sequencer node performs basic validation checks on transactions before including them in a batch. This involves verifying signatures, ensuring sufficient user balances, and adhering to Laïka's transaction format.

  3. Batch Creation: The sequencer efficiently aggregates validated L2 transactions into batches to optimize gas consumption during interaction with L1 smart contracts.


Submitting Sequencer Packages

Once L2 transactions are batched, the sequencer prepares and submits a sequencer package to Laïka's L2 contracts:

  • Package Preparation: The sequencer package includes the batched L2 transactions, along with the corresponding Proofs for data availability verification. You can refer to the previous section (Layer 1 Interaction) for details on proofs.

  • Smart Contract Interaction: The sequencer submits the sequencer package to the designated Laïka smart contract . This allows validators on the L2 network to access the batched transactions and verify their inclusion through the provided proof.

Last updated