From 7f66010c512a026e0fe8115a6c09b246c8c9d995 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Thu, 10 Jul 2025 16:31:42 +0200 Subject: [PATCH 01/19] reorganize DA --- .vitepress/config.ts | 12 +++--- guides/da/overview.md | 76 -------------------------------------- learn/data-availability.md | 41 ++++++++++++++++++++ 3 files changed, 47 insertions(+), 82 deletions(-) delete mode 100644 guides/da/overview.md create mode 100644 learn/data-availability.md diff --git a/.vitepress/config.ts b/.vitepress/config.ts index e8052b79b..ea268014b 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -195,6 +195,10 @@ function sidebarHome() { { text: "Transaction flow", link: "/learn/transaction-flow" }, ], }, + { + text: "Data Availability", + link: "/learn/data-availability", + }, { text: "Resources", collapsed: true, @@ -218,15 +222,11 @@ function sidebarHome() { collapsed: true, items: [ { - text: "Overview", - link: "/guides/da/overview", - }, - { - text: "Local DA", + text: "Deploy A Local DA", link: "/guides/da/local-da", }, { - text: "Celestia", + text: "Connect to Celestia", link: "/guides/da/celestia-da", }, ], diff --git a/guides/da/overview.md b/guides/da/overview.md deleted file mode 100644 index 05566e6f8..000000000 --- a/guides/da/overview.md +++ /dev/null @@ -1,76 +0,0 @@ ---- -description: This page provides an overview of how rollkit integrates with DA. ---- - - - -# DA - -Now that you have the foundations of running and building a rollup with Rollkit, it is time to start customizing it to fit your needs. - -The first choice you need to make is which data availability (DA) layer to use. The DA layer is a critical component of a blockchain, as it provides the data availability and finality guarantees that your chain needs to operate securely. - -Rollkit uses the [core da interface](https://github.com/rollkit/rollkit/blob/main/core/da/da.go#L11) to communicate to DA layers. Any DA layer that implements this interface can be used with Rollkit. - -## DA {#go-da} - -The [DA interface](https://github.com/rollkit/rollkit/blob/main/core/da/da.go#L11) defines the core functions required to interact with a DA layer. Probably the two most important functions being `Get` and `Submit`. - -```go -// DA defines very generic interface for interaction with Data Availability layers. -type DA interface { - // Get returns Blob for each given ID, or an error. - // - // Error should be returned if ID is not formatted properly, there is no Blob for given ID or any other client-level - // error occurred (dropped connection, timeout, etc). - Get(ctx context.Context, ids []ID, namespace []byte) ([]Blob, error) - - // GetIDs returns IDs of all Blobs located in DA at given height. - GetIDs(ctx context.Context, height uint64, namespace []byte) (*GetIDsResult, error) - - // GetProofs returns inclusion Proofs for Blobs specified by their IDs. - GetProofs(ctx context.Context, ids []ID, namespace []byte) ([]Proof, error) - - // Commit creates a Commitment for each given Blob. - Commit(ctx context.Context, blobs []Blob, namespace []byte) ([]Commitment, error) - - // Submit submits the Blobs to Data Availability layer. - // - // This method is synchronous. Upon successful submission to Data Availability layer, it returns the IDs identifying blobs - // in DA. - Submit(ctx context.Context, blobs []Blob, gasPrice float64, namespace []byte) ([]ID, error) - - // SubmitWithOptions submits the Blobs to Data Availability layer with additional options. - SubmitWithOptions(ctx context.Context, blobs []Blob, gasPrice float64, namespace []byte, options []byte) ([]ID, error) - - // Validate validates Commitments against the corresponding Proofs. This should be possible without retrieving the Blobs. - Validate(ctx context.Context, ids []ID, proofs []Proof, namespace []byte) ([]bool, error) - - // GasPrice returns the gas price for the DA layer. - GasPrice(ctx context.Context) (float64, error) - - // GasMultiplier returns the gas multiplier for the DA layer. - GasMultiplier(ctx context.Context) (float64, error) -} -``` - - DA layers can integrate the `DA` interface directly into their node like [Celestia DA](celestia-da.md). - -## Mock DA {#mock-da} - -You might have noticed that we did not define any DA layer during the [quick start](/guides/quick-start.md) or [build a chain](/guides/gm-world.md) tutorials. This is because we used a mock DA layer that is built into Rollkit. - -If you revisit the logs from those tutorials, you will see one of the first lines being: - -```shell -I[2024-11-15|14:09:41.735] Starting mock DA server module=main address=http://localhost:26658 -``` - -The mock DA layer is a simple in-memory DA layer that is great for testing and development. It is not suitable for production use, as it does not provide the data availability and finality guarantees that a real DA layer would. - -## DA Layers {#da-layers} - -Now that you have a better understanding of what a DA layer is, you can start to explore the different DA layers that are available to use with Rollkit. - -* [Local DA](/guides/da/local-da.md) -* [Celestia DA](/guides/da/celestia-da.md) diff --git a/learn/data-availability.md b/learn/data-availability.md new file mode 100644 index 000000000..ec6039e36 --- /dev/null +++ b/learn/data-availability.md @@ -0,0 +1,41 @@ +# Data Availability in Rollkit + +Data availability (DA) is a core component of Rollkit's modular rollup framework. In Rollkit, data availability ensures that all transaction data and block information required to verify the rollup's state is accessible to anyone running a node or light client. + +## How Rollkit Handles Data Availability + +Rollkit is designed to be DA-agnostic, meaning it can integrate with different data availability layers depending on your needs. The main options are: + +- **Mock Data Availability (Mock DA):** + - Simple in-memory DA layer that is great for testing and development. + - Data is stored and served by the rollup node itself. + - Not secure for production, as data can be withheld by the node operator. + +- **Local Data Availability (Local DA):** + - Used for development, testing, and local deployments. + - Not secure for production, as data can be withheld by the node operator. + +- **External Data Availability Layer (DA Interface):** + - Used for production and secure deployments. + - Rollkit can post block data to any external DA layer that implements the Rollkit [DA interface](https://github.com/rollkit/rollkit/blob/main/core/da/da.go#L11) (e.g., Celestia). + - Anyone can verify that the data is available and reconstruct the rollup state, depending on the guarantees of the chosen DA layer. + +## Why Data Availability Matters in Rollkit + +- **Fraud Proofs and Security:** + - Rollkit rollups rely on data availability to enable fraud proofs and ensure that invalid state transitions can be challenged. + - If data is unavailable, users cannot verify the rollup's state or submit fraud proofs. + +- **Interoperability:** + - By supporting multiple DA layers, Rollkit enables rollups to be deployed in a variety of environments, from local devnets to scalable, decentralized networks. + +## Best Practices + +- **Use Mock or Local DA only for development and testing.** +- **For production, always use a decentralized DA layer that implements the Rollkit DA interface.** + +## Learn More + +- [Set up a local DA](/guides/da/local-da.md) +- [Set up Celestia DA](/guides/da/celestia-da.md) +- [Celestia Docs](https://docs.celestia.org/) From 8c5fc179ab6a53218b243461a66fb9688149ead5 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Thu, 10 Jul 2025 17:03:48 +0200 Subject: [PATCH 02/19] reorganize Sequencing --- .vitepress/config.ts | 10 +++++ guides/sequencing/single.md | 1 - {guides => learn}/sequencing/based.md | 0 .../sequencing/forced-inclusion.md | 0 {guides => learn}/sequencing/overview.md | 12 +++--- learn/sequencing/single.md | 41 +++++++++++++++++++ 6 files changed, 58 insertions(+), 6 deletions(-) delete mode 100644 guides/sequencing/single.md rename {guides => learn}/sequencing/based.md (100%) rename {guides => learn}/sequencing/forced-inclusion.md (100%) rename {guides => learn}/sequencing/overview.md (64%) create mode 100644 learn/sequencing/single.md diff --git a/.vitepress/config.ts b/.vitepress/config.ts index ea268014b..17fe6d1ab 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -199,6 +199,16 @@ function sidebarHome() { text: "Data Availability", link: "/learn/data-availability", }, + { + text: "Sequencing", + collapsed: true, + items: [ + { text: "Overview", link: "/lean/sequencing/overview" }, + { text: "Single", link: "/lean/sequencing/single" }, + { text: "Based", link: "/lean/sequencing/based" }, + { text: "Forced Inclusion", link: "/lean/sequencing/forced-inclusion" }, + ], + }, { text: "Resources", collapsed: true, diff --git a/guides/sequencing/single.md b/guides/sequencing/single.md deleted file mode 100644 index 36ab13a10..000000000 --- a/guides/sequencing/single.md +++ /dev/null @@ -1 +0,0 @@ -# Single Sequencer diff --git a/guides/sequencing/based.md b/learn/sequencing/based.md similarity index 100% rename from guides/sequencing/based.md rename to learn/sequencing/based.md diff --git a/guides/sequencing/forced-inclusion.md b/learn/sequencing/forced-inclusion.md similarity index 100% rename from guides/sequencing/forced-inclusion.md rename to learn/sequencing/forced-inclusion.md diff --git a/guides/sequencing/overview.md b/learn/sequencing/overview.md similarity index 64% rename from guides/sequencing/overview.md rename to learn/sequencing/overview.md index c724aafbe..1aea36a8e 100644 --- a/guides/sequencing/overview.md +++ b/learn/sequencing/overview.md @@ -22,9 +22,11 @@ It mainly consists of: ## Sequencing Implementations {#sequencing-implementations} -An implementation of the sequencing interface mainly acts as a middleware that connects Rollkit rollup and the sequencing layer. It implements the sequencing interface functions described above. For example, [single-sequencer](https://github.com/rollkit/rollkit/blob/main/sequencers/single/README.md) is the refactored functionality from the Rollkit prior to `v1.0.0`. The single sequencer is the middleware run by the aggregator node of the Rollkit rollup. The aggregator node relays rollup transactions to single sequencer which then submits them to the DA network (Celestia). The header producer node then retrieves (via `GetNextBatch`) the batched transaction from the single sequencer to execute the transactions and produce the updated rollup state. Similarly, there are other sequencing middlewares which can be built for various sequencing strategies or even for connecting to different third-party sequencing networks. +An implementation of the sequencing interface mainly acts as a middleware that connects Rollkit rollup and the sequencing layer. It implements the sequencing interface functions described above. +There are several implementations of the sequencor: -The sequencing implementations that are currently work in progress: - -* [based-sequencer](/guides/sequencing/based.md) -* [forced-inclusion-sequencer](/guides/sequencing/forced-inclusion.md) +* [single-sequencer](/guides/sequencing/single.md) - The simplest and most widely used sequencing model, where a single node (the sequencer) is responsible for ordering transactions and producing blocks. + +* [based-sequencer](/guides/sequencing/based.md) - A more decentralized model where multiple sequencers work together to order transactions and produce blocks, improving censorship resistance (Not available yet). + +* [forced-inclusion-sequencer](/guides/sequencing/forced-inclusion.md) - A model that ensures all transactions are included in the rollup, even if they are not ordered by the sequencer, providing strong guarantees against censorship. (Not available yet). \ No newline at end of file diff --git a/learn/sequencing/single.md b/learn/sequencing/single.md new file mode 100644 index 000000000..7f170929f --- /dev/null +++ b/learn/sequencing/single.md @@ -0,0 +1,41 @@ +# Single Sequencer + +A single sequencer is the simplest sequencing architecture for a Rollkit-based rollup. In this model, one node (the sequencer) is responsible for ordering transactions, producing blocks, and submitting data to the data availability (DA) layer. + +## How the Single Sequencer Model Works + +1. **Transaction Submission:** + - Users submit transactions directly to the sequencer node via RPC or other interfaces. +2. **Transaction Ordering:** + - The sequencer collects transactions from users and orders them into blocks according to the rollup's rules. +3. **Block Production:** + - The sequencer produces new blocks at regular intervals or when enough transactions are collected. + - Each block contains a batch of ordered transactions and metadata. + +4. **Data Availability Posting:** + - The sequencer posts the block data to the configured DA layer (e.g., Celestia, Avail, etc.). + - This ensures that anyone can access the data needed to reconstruct the rollup state. + +5. **State Update:** + - The sequencer updates the rollup state based on the new block and makes the updated state available to light clients and full nodes. + +## Advantages + +- **Simplicity:** Easy to set up and operate, making it ideal for development, testing, and small-scale deployments. +- **Low Latency:** Fast block production and transaction inclusion, since there is no consensus overhead among multiple sequencers. + +## Considerations + +- **Centralization:** The sequencer is a single point of control. However, this is often acceptable for many applications, especially in early stages or permissioned environments. +- **No Fault Tolerance:** If the sequencer is unavailable, the rollup cannot make progress. High-availability setups and monitoring can mitigate this risk. + +## Use Cases + +- Production rollups seeking simplicity and performance +- Prototyping and development +- Private or permissioned rollups +- Projects that value deterministic ordering and operational control + +## Future-Proofing + +While the single sequencer model is robust and production-ready, Rollkit is designed to support more advanced sequencing architectures in the future. Projects can seamlessly upgrade to decentralized sequencing when the technology and their needs mature. From 991388993d23af791714dd10fe24cab9d091155b Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Thu, 10 Jul 2025 19:32:46 +0200 Subject: [PATCH 03/19] fix links --- .vitepress/config.ts | 8 ++++---- learn/sequencing/overview.md | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.vitepress/config.ts b/.vitepress/config.ts index 17fe6d1ab..eddb44926 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -247,19 +247,19 @@ function sidebarHome() { items: [ { text: "Overview", - link: "/guides/sequencing/overview", + link: "/learn/sequencing/overview", }, { text: "Single", - link: "/guides/sequencing/single", + link: "/learn/sequencing/single", }, { text: "Based", - link: "/guides/sequencing/based", + link: "/learn/sequencing/based", }, { text: "Forced Inclusion", - link: "/guides/sequencing/forced-inclusion", + link: "/learn/sequencing/forced-inclusion", }, ], }, diff --git a/learn/sequencing/overview.md b/learn/sequencing/overview.md index 1aea36a8e..274be0f2a 100644 --- a/learn/sequencing/overview.md +++ b/learn/sequencing/overview.md @@ -25,8 +25,8 @@ It mainly consists of: An implementation of the sequencing interface mainly acts as a middleware that connects Rollkit rollup and the sequencing layer. It implements the sequencing interface functions described above. There are several implementations of the sequencor: -* [single-sequencer](/guides/sequencing/single.md) - The simplest and most widely used sequencing model, where a single node (the sequencer) is responsible for ordering transactions and producing blocks. +* [single-sequencer](/learn/sequencing/single.md) - The simplest and most widely used sequencing model, where a single node (the sequencer) is responsible for ordering transactions and producing blocks. -* [based-sequencer](/guides/sequencing/based.md) - A more decentralized model where multiple sequencers work together to order transactions and produce blocks, improving censorship resistance (Not available yet). +* [based-sequencer](/learn/sequencing/based.md) - A more decentralized model where multiple sequencers work together to order transactions and produce blocks, improving censorship resistance (Not available yet). -* [forced-inclusion-sequencer](/guides/sequencing/forced-inclusion.md) - A model that ensures all transactions are included in the rollup, even if they are not ordered by the sequencer, providing strong guarantees against censorship. (Not available yet). \ No newline at end of file +* [forced-inclusion-sequencer](/learn/sequencing/forced-inclusion.md) - A model that ensures all transactions are included in the rollup, even if they are not ordered by the sequencer, providing strong guarantees against censorship. (Not available yet). \ No newline at end of file From 07e7f4bc587fc12ed98833c4ca5aad1f0da30199 Mon Sep 17 00:00:00 2001 From: Pierrick <9058370+pthmas@users.noreply.github.com> Date: Thu, 10 Jul 2025 19:38:36 +0200 Subject: [PATCH 04/19] Update .vitepress/config.ts Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> --- .vitepress/config.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.vitepress/config.ts b/.vitepress/config.ts index eddb44926..59131aae5 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -203,10 +203,10 @@ function sidebarHome() { text: "Sequencing", collapsed: true, items: [ - { text: "Overview", link: "/lean/sequencing/overview" }, - { text: "Single", link: "/lean/sequencing/single" }, - { text: "Based", link: "/lean/sequencing/based" }, - { text: "Forced Inclusion", link: "/lean/sequencing/forced-inclusion" }, + { text: "Overview", link: "/learn/sequencing/overview" }, + { text: "Single", link: "/learn/sequencing/single" }, + { text: "Based", link: "/learn/sequencing/based" }, + { text: "Forced Inclusion", link: "/learn/sequencing/forced-inclusion" }, ], }, { From ea561944e7acb379816a3fa985b9bba9a9a20466 Mon Sep 17 00:00:00 2001 From: Pierrick <9058370+pthmas@users.noreply.github.com> Date: Thu, 10 Jul 2025 19:39:03 +0200 Subject: [PATCH 05/19] Update learn/sequencing/overview.md Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> --- learn/sequencing/overview.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/learn/sequencing/overview.md b/learn/sequencing/overview.md index 274be0f2a..a7f2e45bb 100644 --- a/learn/sequencing/overview.md +++ b/learn/sequencing/overview.md @@ -23,7 +23,7 @@ It mainly consists of: ## Sequencing Implementations {#sequencing-implementations} An implementation of the sequencing interface mainly acts as a middleware that connects Rollkit rollup and the sequencing layer. It implements the sequencing interface functions described above. -There are several implementations of the sequencor: +There are several implementations of the sequencer: * [single-sequencer](/learn/sequencing/single.md) - The simplest and most widely used sequencing model, where a single node (the sequencer) is responsible for ordering transactions and producing blocks. From 50ad747b7bbfa4680dfb8a3779f03a0ee1007dac Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 17:21:26 +0200 Subject: [PATCH 06/19] move evm stuff to their own folder --- guides/{ => evm}/evm-based.md | 0 guides/{ => evm}/evm-reth-backup.md | 0 guides/{ => evm}/evm-single.md | 0 3 files changed, 0 insertions(+), 0 deletions(-) rename guides/{ => evm}/evm-based.md (100%) rename guides/{ => evm}/evm-reth-backup.md (100%) rename guides/{ => evm}/evm-single.md (100%) diff --git a/guides/evm-based.md b/guides/evm/evm-based.md similarity index 100% rename from guides/evm-based.md rename to guides/evm/evm-based.md diff --git a/guides/evm-reth-backup.md b/guides/evm/evm-reth-backup.md similarity index 100% rename from guides/evm-reth-backup.md rename to guides/evm/evm-reth-backup.md diff --git a/guides/evm-single.md b/guides/evm/evm-single.md similarity index 100% rename from guides/evm-single.md rename to guides/evm/evm-single.md From 75ba3d77add5d12fd4598ded026a19c4d2b2e0a4 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 17:21:53 +0200 Subject: [PATCH 07/19] add learn page for abci execution --- learn/execution/abci.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 learn/execution/abci.md diff --git a/learn/execution/abci.md b/learn/execution/abci.md new file mode 100644 index 000000000..8796e36ce --- /dev/null +++ b/learn/execution/abci.md @@ -0,0 +1,29 @@ +# ABCI-Compatible Execution Layers in Rollkit + +Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. This means you can use a variety of ABCI-compatible applications as the execution environment for your rollup. + +## Supported Execution Layers + +### Cosmos SDK App +A Cosmos SDK-based application can serve as the execution layer for a Rollkit rollup. This allows you to leverage the rich ecosystem and features of the Cosmos SDK, including modules for staking, governance, IBC, and more. + +- [Cosmos SDK Documentation](https://docs.cosmos.network/) + +### CosmWasm +CosmWasm is a smart contract platform built for the Cosmos ecosystem. It is ABCI-compatible and can be integrated as the execution layer in Rollkit, enabling your rollup to support WebAssembly (Wasm) smart contracts. + +- [CosmWasm Documentation](https://docs.cosmwasm.com/) + +## How It Works + +- Rollkit acts as the consensus and data availability layer. +- The execution layer (Cosmos SDK app or CosmWasm) processes transactions and maintains application state. +- Communication between Rollkit and the execution layer happens via the ABCI protocol. + +## Benefits + +- **Modularity:** Choose the execution environment that best fits your use case. +- **Interoperability:** Leverage existing Cosmos SDK modules or deploy CosmWasm smart contracts. +- **Extensibility:** Easily upgrade or swap out the execution layer as your rollup evolves. + +For more details on integrating an execution layer with Rollkit, see the respective documentation links above. From cb9f7ac850ed0058e930e30789afaf002b10cb43 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 17:29:20 +0200 Subject: [PATCH 08/19] Update DA docs --- learn/data-availability.md | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/learn/data-availability.md b/learn/data-availability.md index ec6039e36..4f9d4dc06 100644 --- a/learn/data-availability.md +++ b/learn/data-availability.md @@ -2,15 +2,15 @@ Data availability (DA) is a core component of Rollkit's modular rollup framework. In Rollkit, data availability ensures that all transaction data and block information required to verify the rollup's state is accessible to anyone running a node or light client. +Learn more about data availability: + +- [What is DA](https://celestia.org/what-is-da/) +- [The importance of DA for Rollups](https://medium.com/zeeve/exploring-data-availability-layer-and-its-importance-in-rollups-0a4fbf2e0ffc) + ## How Rollkit Handles Data Availability Rollkit is designed to be DA-agnostic, meaning it can integrate with different data availability layers depending on your needs. The main options are: -- **Mock Data Availability (Mock DA):** - - Simple in-memory DA layer that is great for testing and development. - - Data is stored and served by the rollup node itself. - - Not secure for production, as data can be withheld by the node operator. - - **Local Data Availability (Local DA):** - Used for development, testing, and local deployments. - Not secure for production, as data can be withheld by the node operator. @@ -26,12 +26,10 @@ Rollkit is designed to be DA-agnostic, meaning it can integrate with different d - Rollkit rollups rely on data availability to enable fraud proofs and ensure that invalid state transitions can be challenged. - If data is unavailable, users cannot verify the rollup's state or submit fraud proofs. -- **Interoperability:** - - By supporting multiple DA layers, Rollkit enables rollups to be deployed in a variety of environments, from local devnets to scalable, decentralized networks. - ## Best Practices -- **Use Mock or Local DA only for development and testing.** +- **Use Local DA only for development and testing locally.** +- **Alternatively, you can use [Celestia testnets](https://docs.celestia.org/how-to-guides/participate).** - **For production, always use a decentralized DA layer that implements the Rollkit DA interface.** ## Learn More From 9fe5df4a82e90d87b3f020cd3b3b743144ad1f18 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 17:54:23 +0200 Subject: [PATCH 09/19] updated abci docs --- learn/execution/abci.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/learn/execution/abci.md b/learn/execution/abci.md index 8796e36ce..43754ea97 100644 --- a/learn/execution/abci.md +++ b/learn/execution/abci.md @@ -1,6 +1,8 @@ # ABCI-Compatible Execution Layers in Rollkit -Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. This means you can use a variety of ABCI-compatible applications as the execution environment for your rollup. +Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any ABCI-compatible application as the rollup's execution layer. + +This means you can use a variety of ABCI-compatible applications as the execution environment for your rollup. ## Supported Execution Layers From 1527dfb0fbfbaac5bdb5a84660b2252451c84b93 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 17:54:41 +0200 Subject: [PATCH 10/19] updated sequencing docs --- learn/sequencing/forced-inclusion.md | 3 --- learn/sequencing/overview.md | 6 +----- learn/sequencing/single.md | 9 --------- 3 files changed, 1 insertion(+), 17 deletions(-) delete mode 100644 learn/sequencing/forced-inclusion.md diff --git a/learn/sequencing/forced-inclusion.md b/learn/sequencing/forced-inclusion.md deleted file mode 100644 index baae98546..000000000 --- a/learn/sequencing/forced-inclusion.md +++ /dev/null @@ -1,3 +0,0 @@ -# Forced Inclusion - -Coming soon ... diff --git a/learn/sequencing/overview.md b/learn/sequencing/overview.md index a7f2e45bb..f8b60b285 100644 --- a/learn/sequencing/overview.md +++ b/learn/sequencing/overview.md @@ -23,10 +23,6 @@ It mainly consists of: ## Sequencing Implementations {#sequencing-implementations} An implementation of the sequencing interface mainly acts as a middleware that connects Rollkit rollup and the sequencing layer. It implements the sequencing interface functions described above. -There are several implementations of the sequencer: +There are several implementations of the sequencer but for now only one is available in Rollkit. * [single-sequencer](/learn/sequencing/single.md) - The simplest and most widely used sequencing model, where a single node (the sequencer) is responsible for ordering transactions and producing blocks. - -* [based-sequencer](/learn/sequencing/based.md) - A more decentralized model where multiple sequencers work together to order transactions and produce blocks, improving censorship resistance (Not available yet). - -* [forced-inclusion-sequencer](/learn/sequencing/forced-inclusion.md) - A model that ensures all transactions are included in the rollup, even if they are not ordered by the sequencer, providing strong guarantees against censorship. (Not available yet). \ No newline at end of file diff --git a/learn/sequencing/single.md b/learn/sequencing/single.md index 7f170929f..a0d93810f 100644 --- a/learn/sequencing/single.md +++ b/learn/sequencing/single.md @@ -24,18 +24,9 @@ A single sequencer is the simplest sequencing architecture for a Rollkit-based r - **Simplicity:** Easy to set up and operate, making it ideal for development, testing, and small-scale deployments. - **Low Latency:** Fast block production and transaction inclusion, since there is no consensus overhead among multiple sequencers. -## Considerations - -- **Centralization:** The sequencer is a single point of control. However, this is often acceptable for many applications, especially in early stages or permissioned environments. -- **No Fault Tolerance:** If the sequencer is unavailable, the rollup cannot make progress. High-availability setups and monitoring can mitigate this risk. - ## Use Cases - Production rollups seeking simplicity and performance - Prototyping and development - Private or permissioned rollups - Projects that value deterministic ordering and operational control - -## Future-Proofing - -While the single sequencer model is robust and production-ready, Rollkit is designed to support more advanced sequencing architectures in the future. Projects can seamlessly upgrade to decentralized sequencing when the technology and their needs mature. From 62b3fbe382d678f1a0c60a4d043ed775fb882880 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Fri, 11 Jul 2025 18:09:19 +0200 Subject: [PATCH 11/19] cleanups and changes after review --- .vitepress/config.ts | 62 +++--- guides/evm/evm-based.md | 182 ------------------ .../{evm-reth-backup.md => reth-backup.md} | 0 guides/evm/{evm-single.md => single.md} | 0 learn/data-availability.md | 2 +- learn/sequencing/based.md | 3 - 6 files changed, 23 insertions(+), 226 deletions(-) delete mode 100644 guides/evm/evm-based.md rename guides/evm/{evm-reth-backup.md => reth-backup.md} (100%) rename guides/evm/{evm-single.md => single.md} (100%) delete mode 100644 learn/sequencing/based.md diff --git a/.vitepress/config.ts b/.vitepress/config.ts index 59131aae5..57c3b3556 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -193,6 +193,7 @@ function sidebarHome() { items: [ { text: "Rollkit stack", link: "/learn/stack" }, { text: "Transaction flow", link: "/learn/transaction-flow" }, + { text: "Configuration", link: "/learn/config" }, ], }, { @@ -205,8 +206,13 @@ function sidebarHome() { items: [ { text: "Overview", link: "/learn/sequencing/overview" }, { text: "Single", link: "/learn/sequencing/single" }, - { text: "Based", link: "/learn/sequencing/based" }, - { text: "Forced Inclusion", link: "/learn/sequencing/forced-inclusion" }, + ], + }, + { + text: "Execution", + collapsed: true, + items: [ + { text: "ABCI", link: "/learn/execution/abci" }, ], }, { @@ -241,28 +247,6 @@ function sidebarHome() { }, ], }, - { - text: "Sequencing", - collapsed: true, - items: [ - { - text: "Overview", - link: "/learn/sequencing/overview", - }, - { - text: "Single", - link: "/learn/sequencing/single", - }, - { - text: "Based", - link: "/learn/sequencing/based", - }, - { - text: "Forced Inclusion", - link: "/learn/sequencing/forced-inclusion", - }, - ], - }, { text: "Execution", collapsed: true, @@ -284,6 +268,20 @@ function sidebarHome() { }, ], }, + { + text: "EVM", + collapsed: true, + items: [ + { + text: "EVM Single Sequencer", + link: "/guides/evm/single", + }, + { + text: "EVM reth state backup", + link: "/guides/evm/reth-backup", + }, + ] + }, { text: "Run a Full Node", link: "/guides/full-node", @@ -304,22 +302,6 @@ function sidebarHome() { text: "Create genesis for your rollup", link: "/guides/create-genesis", }, - { - text: "Configuration", - link: "/guides/config", - }, - { - text: "EVM Single Sequencer", - link: "/guides/evm-single", - }, - { - text: "EVM Based Sequencer", - link: "/guides/evm-based", - }, - { - text: "EVM reth state backup", - link: "/guides/evm-reth-backup", - }, { text: "Metrics", link: "/guides/metrics", diff --git a/guides/evm/evm-based.md b/guides/evm/evm-based.md deleted file mode 100644 index b9b230c2c..000000000 --- a/guides/evm/evm-based.md +++ /dev/null @@ -1,182 +0,0 @@ -# Rollkit EVM Based Sequencer Setup Guide - -## Introduction - -This guide covers how to set up and run the Based Sequencer implementation of Rollkit EVM rollups. This implementation provides a DA-based approach to transaction sequencing while using EVM as the execution layer. - -## Prerequisites - -Before starting, ensure you have: - -- Go 1.20 or later -- Docker and Docker Compose -- Access to the go-execution-evm repository (op-geth branch) -- Git - -## Setting Up the Environment - -### 1. Clone the Rollkit Repository - -```bash -git clone https://github.com/rollkit/rollkit.git -cd rollkit -``` - -### 2. Build the Rollkit EVM Based Sequencer Implementation - -```bash -make build-evm-based -make build-da -``` - -This will create the following binaries in the `build` directory: - -- `evm-based` - Based sequencer implementation -- `local-da` - Local data availability node for testing - -## Setting Up the Data Availability (DA) Layer - -### Start the Local DA Node - -```bash -cd build -./local-da start -``` - -This will start a local DA node on the default port (26658). - -## Setting Up the EVM Layer - -### 1. Clone the go-execution-evm Repository - -```bash -git clone https://github.com/rollkit/go-execution-evm.git -cd go-execution-evm -git checkout op-geth -``` - -### 2. Start the EVM Layer Using Docker Compose - -```bash -docker compose up -d -``` - -This will start Reth (Rust Ethereum client) with the appropriate configuration for Rollkit. - -### 3. Note the JWT Secret Path - -The JWT secret is typically located at `go-execution-evm/docker/jwttoken/jwt.hex`. You'll need this path for the sequencer configuration. - -## Running the Based Sequencer Implementation - -### 1. Initialize the Sequencer - -```bash -cd build -./evm-based init --rollkit.node.aggregator=true --rollkit.signer.passphrase secret -``` - -### 2. Start the Sequencer - -```bash -./evm-based start \ - --evm.jwt-secret $(cat /path/to/go-execution-evm/docker/jwttoken/jwt.hex) \ - --evm.genesis-hash 0x0a962a0d163416829894c89cb604ae422323bcdf02d7ea08b94d68d3e026a380 \ - --rollkit.node.block_time 1s \ - --rollkit.node.aggregator=true \ - --rollkit.signer.passphrase secret \ - --based.url http://localhost:26658 \ - --based.namespace 0102030405060708090a \ - --based.start-height 0 \ - --based.max-height-drift 1 \ - --based.gas-multiplier 1.0 \ - --based.gas-price 1.0 -``` - -Replace `/path/to/` with the actual path to your go-execution-evm repository. - -## Setting Up a Full Node - -To run a full node alongside your sequencer, follow these steps: - -### 1. Initialize a New Node Directory - -```bash -./evm-based init --home ~/.rollkit/evm-based-fullnode -``` - -### 2. Copy the Genesis File - -Copy the genesis file from the sequencer node to the full node: - -```bash -cp ~/.rollkit/evm-based/config/genesis.json ~/.rollkit/evm-based-fullnode/config/ -``` - -### 3. Get the Sequencer's P2P Address - -Find the sequencer's P2P address in its logs. It will look similar to: - -```bash -INF listening on address=/ip4/127.0.0.1/tcp/26659/p2p/12D3KooWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX -``` - -### 4. Start the Full Node - -```bash -./evm-based start \ - --home ~/.rollkit/evm-based-fullnode \ - --evm.jwt-secret $(cat /path/to/go-execution-evm/docker/jwttoken/jwt.hex) \ - --evm.genesis-hash 0x0a962a0d163416829894c89cb604ae422323bcdf02d7ea08b94d68d3e026a380 \ - --rollkit.node.block_time 1s \ - --rollkit.node.aggregator=false \ - --rollkit.p2p.peers @127.0.0.1:26659 \ - --based.url http://localhost:26658 \ - --based.namespace 0102030405060708090a -``` - -Replace `` with the actual P2P ID from your sequencer's logs. - -## Verifying Node Operation - -After starting your nodes, you should see logs indicating successful block processing: - -```bash -INF block marked as DA included blockHash=XXXX blockHeight=XX module=BlockManager -``` - -## Configuration Reference - -### Common Flags - -| Flag | Description | -|------|-------------| -| `--rollkit.node.aggregator` | Set to true for sequencer mode, false for full node | -| `--rollkit.signer.passphrase` | Passphrase for the signer | -| `--rollkit.node.block_time` | Block time for the Rollkit node | - -### EVM Flags - -| Flag | Description | -|------|-------------| -| `--evm.eth-url` | Ethereum JSON-RPC URL (default `http://localhost:8545`) | -| `--evm.engine-url` | Engine API URL (default `http://localhost:8551`) | -| `--evm.jwt-secret` | JWT secret file path for the Engine API | -| `--evm.genesis-hash` | Genesis block hash of the chain | -| `--evm.fee-recipient` | Address to receive priority fees | - -### Based Sequencer Flags - -| Flag | Description | -|------|-------------| -| `--based.url` | URL for DA endpoint (default `http://localhost:26658`) | -| `--based.auth` | Auth token for based DA layer | -| `--based.namespace` | Hex-encoded namespace ID for submitting rollup transactions | -| `--based.start-height` | Starting DA height for fetching transactions (default `0`) | -| `--based.max-height-drift` | Max number of DA heights to look ahead during batching (default `1`) | -| `--based.gas-multiplier` | Gas multiplier to apply on DA submission (default `1.0`) | -| `--based.gas-price` | Base gas price to use during DA submission (default `1.0`) | - -## Conclusion - -You've now set up and configured the Based Sequencer implementation of Rollkit EVM rollups. This implementation provides a DA-based approach to transaction sequencing while using EVM as the execution layer. diff --git a/guides/evm/evm-reth-backup.md b/guides/evm/reth-backup.md similarity index 100% rename from guides/evm/evm-reth-backup.md rename to guides/evm/reth-backup.md diff --git a/guides/evm/evm-single.md b/guides/evm/single.md similarity index 100% rename from guides/evm/evm-single.md rename to guides/evm/single.md diff --git a/learn/data-availability.md b/learn/data-availability.md index 4f9d4dc06..8ad8e011c 100644 --- a/learn/data-availability.md +++ b/learn/data-availability.md @@ -1,6 +1,6 @@ # Data Availability in Rollkit -Data availability (DA) is a core component of Rollkit's modular rollup framework. In Rollkit, data availability ensures that all transaction data and block information required to verify the rollup's state is accessible to anyone running a node or light client. +Data availability (DA) is a core of Rollkit's. Rollkit utilize's data availability ensures that all transaction data and block information required to verify the rollup's state is accessible to anyone running a node or light client. Learn more about data availability: diff --git a/learn/sequencing/based.md b/learn/sequencing/based.md deleted file mode 100644 index 9fcbf573a..000000000 --- a/learn/sequencing/based.md +++ /dev/null @@ -1,3 +0,0 @@ -# Based Sequencing - -Coming soon ... From 31f26009db8eafaec3ce6c979df9df44e37cbcfa Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Mon, 14 Jul 2025 11:06:20 +0200 Subject: [PATCH 12/19] rework the execution part --- .vitepress/config.ts | 5 +---- learn/execution.md | 40 ++++++++++++++++++++++++++++++++++++++++ learn/execution/abci.md | 31 ------------------------------- 3 files changed, 41 insertions(+), 35 deletions(-) create mode 100644 learn/execution.md delete mode 100644 learn/execution/abci.md diff --git a/.vitepress/config.ts b/.vitepress/config.ts index 57c3b3556..e15a7b142 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -210,10 +210,7 @@ function sidebarHome() { }, { text: "Execution", - collapsed: true, - items: [ - { text: "ABCI", link: "/learn/execution/abci" }, - ], + link: "/learn/execution" }, { text: "Resources", diff --git a/learn/execution.md b/learn/execution.md new file mode 100644 index 000000000..bc01e6895 --- /dev/null +++ b/learn/execution.md @@ -0,0 +1,40 @@ +# Execution Layers in Rollkit + +Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any compatible application as the rollup's execution layer. + +This means you can use a variety of ABCI or Reth compatible applications as the execution environment for your rollup. + +## Supported Execution Layers + +### ABCI-Compatible Execution Layers + +Any ABCI-compatible application can be used as the execution layer for a Rollkit rollup. This flexibility allows developers to choose the best execution environment for their use case, whether it's a custom application or an existing framework. + +A common example is a Cosmos SDK-based application, which provides a rich set of modules for staking, governance, IBC, and more, and is widely used in the Cosmos ecosystem. + +- [Cosmos SDK Documentation](https://docs.cosmos.network/) +- [Cosmos SDK ABCI Documentation](https://docs.cosmos.network/main/build/abci/introduction) +- [Rollkit ABCI Adapter](https://github.com/rollkit/go-execution-abci) + +### Reth + +Reth is a high-performance Ethereum execution client written in Rust. Rollkit can integrate Reth as an execution layer, enabling Ethereum-compatible rollups to process EVM transactions and maintain Ethereum-like state. This allows developers to build rollups that leverage the Ethereum ecosystem, tooling, and smart contracts, while benefiting from Rollkit's modular consensus and data availability. + +For more information about Reth, see the official documentation: + +- [Reth GitHub Repository](https://github.com/paradigmxyz/reth) +- [Rollkit Reth Integration](https://github.com/rollkit/lumen) + +## How It Works + +- Rollkit acts as the consensus and data availability layer. +- The execution layer (Cosmos SDK app or Reth) processes transactions and maintains application state. +- Communication between Rollkit and the execution layer happens via the ABCI protocol or other supported interfaces. + +## Benefits + +- **Modularity:** Choose the execution environment that best fits your use case. +- **Interoperability:** Leverage existing Cosmos SDK modules, deploy CosmWasm smart contracts, or use EVM tooling with Reth. +- **Extensibility:** Easily upgrade or swap out the execution layer as your rollup evolves. + +For more details on integrating an execution layer with Rollkit, see the respective documentation links above. diff --git a/learn/execution/abci.md b/learn/execution/abci.md deleted file mode 100644 index 43754ea97..000000000 --- a/learn/execution/abci.md +++ /dev/null @@ -1,31 +0,0 @@ -# ABCI-Compatible Execution Layers in Rollkit - -Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any ABCI-compatible application as the rollup's execution layer. - -This means you can use a variety of ABCI-compatible applications as the execution environment for your rollup. - -## Supported Execution Layers - -### Cosmos SDK App -A Cosmos SDK-based application can serve as the execution layer for a Rollkit rollup. This allows you to leverage the rich ecosystem and features of the Cosmos SDK, including modules for staking, governance, IBC, and more. - -- [Cosmos SDK Documentation](https://docs.cosmos.network/) - -### CosmWasm -CosmWasm is a smart contract platform built for the Cosmos ecosystem. It is ABCI-compatible and can be integrated as the execution layer in Rollkit, enabling your rollup to support WebAssembly (Wasm) smart contracts. - -- [CosmWasm Documentation](https://docs.cosmwasm.com/) - -## How It Works - -- Rollkit acts as the consensus and data availability layer. -- The execution layer (Cosmos SDK app or CosmWasm) processes transactions and maintains application state. -- Communication between Rollkit and the execution layer happens via the ABCI protocol. - -## Benefits - -- **Modularity:** Choose the execution environment that best fits your use case. -- **Interoperability:** Leverage existing Cosmos SDK modules or deploy CosmWasm smart contracts. -- **Extensibility:** Easily upgrade or swap out the execution layer as your rollup evolves. - -For more details on integrating an execution layer with Rollkit, see the respective documentation links above. From 9f6692af7a0432cc4f2462a9987394698df3847b Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Tue, 15 Jul 2025 15:02:04 +0200 Subject: [PATCH 13/19] update execution --- learn/execution.md | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/learn/execution.md b/learn/execution.md index bc01e6895..d2132514f 100644 --- a/learn/execution.md +++ b/learn/execution.md @@ -1,16 +1,16 @@ # Execution Layers in Rollkit -Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in via the ABCI (Application Blockchain Interface) protocol. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any compatible application as the rollup's execution layer. +Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any compatible application as the rollup's execution layer. -This means you can use a variety of ABCI or Reth compatible applications as the execution environment for your rollup. +This means you can use a variety of Cosmos SDK or Reth compatible applications as the execution environment for your rollup. ## Supported Execution Layers -### ABCI-Compatible Execution Layers +### Cosmos SDK Execution Layer -Any ABCI-compatible application can be used as the execution layer for a Rollkit rollup. This flexibility allows developers to choose the best execution environment for their use case, whether it's a custom application or an existing framework. +Rollkit natively supports Cosmos SDK-based applications as the execution layer for a rollup via the ABCI (Application Blockchain Interface) protocol. The Cosmos SDK provides a rich set of modules for staking, governance, IBC, and more, and is widely used in the Cosmos ecosystem. This integration allows developers to leverage the full power and flexibility of the Cosmos SDK when building their rollup applications. -A common example is a Cosmos SDK-based application, which provides a rich set of modules for staking, governance, IBC, and more, and is widely used in the Cosmos ecosystem. +Take advantage of the Cosmos SDK's built-in modules for staking, governance, and IBC, and extend your rollup with CosmWasm smart contracts for added functionality. - [Cosmos SDK Documentation](https://docs.cosmos.network/) - [Cosmos SDK ABCI Documentation](https://docs.cosmos.network/main/build/abci/introduction) @@ -29,12 +29,10 @@ For more information about Reth, see the official documentation: - Rollkit acts as the consensus and data availability layer. - The execution layer (Cosmos SDK app or Reth) processes transactions and maintains application state. -- Communication between Rollkit and the execution layer happens via the ABCI protocol or other supported interfaces. ## Benefits - **Modularity:** Choose the execution environment that best fits your use case. -- **Interoperability:** Leverage existing Cosmos SDK modules, deploy CosmWasm smart contracts, or use EVM tooling with Reth. - **Extensibility:** Easily upgrade or swap out the execution layer as your rollup evolves. For more details on integrating an execution layer with Rollkit, see the respective documentation links above. From a32996b783251831be4315de6e6dfd7236d9bfb0 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Tue, 15 Jul 2025 15:03:32 +0200 Subject: [PATCH 14/19] update sequencing --- learn/sequencing/single.md | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/learn/sequencing/single.md b/learn/sequencing/single.md index a0d93810f..4bf4476e1 100644 --- a/learn/sequencing/single.md +++ b/learn/sequencing/single.md @@ -5,11 +5,16 @@ A single sequencer is the simplest sequencing architecture for a Rollkit-based r ## How the Single Sequencer Model Works 1. **Transaction Submission:** - - Users submit transactions directly to the sequencer node via RPC or other interfaces. -2. **Transaction Ordering:** - - The sequencer collects transactions from users and orders them into blocks according to the rollup's rules. + - Users submit transactions to the execution environment via RPC or other interfaces. +2. **Transaction Collection and Ordering:** + - The execution environment collects incoming transactions. + - The sequencer requests a batch of transactions from the execution environment to be included in the next block. 3. **Block Production:** - - The sequencer produces new blocks at regular intervals or when enough transactions are collected. + - **Without lazy mode:** the sequencer produces new blocks at fixed intervals. + - **With lazy mode:** the sequencer produces a block once either + - enough transactions are collected + - the lazy-mode block interval elapses + More info [here](/learn/config#lazy-mode). - Each block contains a batch of ordered transactions and metadata. 4. **Data Availability Posting:** @@ -19,6 +24,23 @@ A single sequencer is the simplest sequencing architecture for a Rollkit-based r 5. **State Update:** - The sequencer updates the rollup state based on the new block and makes the updated state available to light clients and full nodes. +## Transaction Flow Diagram + +```mermaid +sequenceDiagram + participant User + participant ExecutionEnv as Execution Environment + participant Sequencer + participant DA as Data Availability Layer + + User->>ExecutionEnv: Submit transaction + Sequencer->>ExecutionEnv: Request batch for block + ExecutionEnv->>Sequencer: Provide batch of transactions + Sequencer->>DA: Post block data + Sequencer->>ExecutionEnv: Update state + ExecutionEnv->>User: State/query response +``` + ## Advantages - **Simplicity:** Easy to set up and operate, making it ideal for development, testing, and small-scale deployments. From 9f451240d43a0f38974ad38626dd02d28257c8c6 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Wed, 16 Jul 2025 12:51:50 +0200 Subject: [PATCH 15/19] udpate execution with latest changes --- learn/execution.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/learn/execution.md b/learn/execution.md index d2132514f..49160b5ba 100644 --- a/learn/execution.md +++ b/learn/execution.md @@ -2,7 +2,7 @@ Rollkit is designed to be modular and flexible, allowing different execution layers to be plugged in. Rollkit defines a general-purpose execution interface ([see execution.go](https://github.com/rollkit/rollkit/blob/main/core/execution/execution.go)) that enables developers to integrate any compatible application as the rollup's execution layer. -This means you can use a variety of Cosmos SDK or Reth compatible applications as the execution environment for your rollup. +This means you can use a variety of Cosmos SDK or Reth compatible applications as the execution environment for your rollup: choose the execution environment that best fits your use case. ## Supported Execution Layers @@ -30,9 +30,5 @@ For more information about Reth, see the official documentation: - Rollkit acts as the consensus and data availability layer. - The execution layer (Cosmos SDK app or Reth) processes transactions and maintains application state. -## Benefits - -- **Modularity:** Choose the execution environment that best fits your use case. -- **Extensibility:** Easily upgrade or swap out the execution layer as your rollup evolves. For more details on integrating an execution layer with Rollkit, see the respective documentation links above. From 16a579e5967b534b7e09a2074b8e63bf25a645f6 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Wed, 16 Jul 2025 13:01:56 +0200 Subject: [PATCH 16/19] updated sequencing/single --- learn/sequencing/single.md | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/learn/sequencing/single.md b/learn/sequencing/single.md index 4bf4476e1..c3d3e8587 100644 --- a/learn/sequencing/single.md +++ b/learn/sequencing/single.md @@ -18,7 +18,7 @@ A single sequencer is the simplest sequencing architecture for a Rollkit-based r - Each block contains a batch of ordered transactions and metadata. 4. **Data Availability Posting:** - - The sequencer posts the block data to the configured DA layer (e.g., Celestia, Avail, etc.). + - The sequencer posts the block data to the configured DA layer (e.g., Celestia). - This ensures that anyone can access the data needed to reconstruct the rollup state. 5. **State Update:** @@ -43,12 +43,7 @@ sequenceDiagram ## Advantages -- **Simplicity:** Easy to set up and operate, making it ideal for development, testing, and small-scale deployments. +- **Simplicity:** Easy to set up and operate, making it ideal for development, testing, and small-scale deployments compared to other more complex sequencers. - **Low Latency:** Fast block production and transaction inclusion, since there is no consensus overhead among multiple sequencers. +- **Independence from DA block time:** The sequencer can produce blocks on its own schedule, without being tied to the block time of the DA layer, enabling more flexible transaction processing than DA-timed sequencers. -## Use Cases - -- Production rollups seeking simplicity and performance -- Prototyping and development -- Private or permissioned rollups -- Projects that value deterministic ordering and operational control From 250364448c6ecaa001977fd99fcf6fb1a6b66b1d Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Wed, 16 Jul 2025 14:33:17 +0200 Subject: [PATCH 17/19] remove section on DA --- learn/data-availability.md | 6 ------ 1 file changed, 6 deletions(-) diff --git a/learn/data-availability.md b/learn/data-availability.md index 8ad8e011c..fe32458b3 100644 --- a/learn/data-availability.md +++ b/learn/data-availability.md @@ -20,12 +20,6 @@ Rollkit is designed to be DA-agnostic, meaning it can integrate with different d - Rollkit can post block data to any external DA layer that implements the Rollkit [DA interface](https://github.com/rollkit/rollkit/blob/main/core/da/da.go#L11) (e.g., Celestia). - Anyone can verify that the data is available and reconstruct the rollup state, depending on the guarantees of the chosen DA layer. -## Why Data Availability Matters in Rollkit - -- **Fraud Proofs and Security:** - - Rollkit rollups rely on data availability to enable fraud proofs and ensure that invalid state transitions can be challenged. - - If data is unavailable, users cannot verify the rollup's state or submit fraud proofs. - ## Best Practices - **Use Local DA only for development and testing locally.** From df17b7fc4d9b68b560dac45412ab025d8d50fd02 Mon Sep 17 00:00:00 2001 From: pthmas <9058370+pthmas@users.noreply.github.com> Date: Wed, 16 Jul 2025 14:41:19 +0200 Subject: [PATCH 18/19] remove repetition --- learn/execution.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/learn/execution.md b/learn/execution.md index 49160b5ba..996a4d9b1 100644 --- a/learn/execution.md +++ b/learn/execution.md @@ -10,8 +10,6 @@ This means you can use a variety of Cosmos SDK or Reth compatible applications a Rollkit natively supports Cosmos SDK-based applications as the execution layer for a rollup via the ABCI (Application Blockchain Interface) protocol. The Cosmos SDK provides a rich set of modules for staking, governance, IBC, and more, and is widely used in the Cosmos ecosystem. This integration allows developers to leverage the full power and flexibility of the Cosmos SDK when building their rollup applications. -Take advantage of the Cosmos SDK's built-in modules for staking, governance, and IBC, and extend your rollup with CosmWasm smart contracts for added functionality. - - [Cosmos SDK Documentation](https://docs.cosmos.network/) - [Cosmos SDK ABCI Documentation](https://docs.cosmos.network/main/build/abci/introduction) - [Rollkit ABCI Adapter](https://github.com/rollkit/go-execution-abci) @@ -30,5 +28,4 @@ For more information about Reth, see the official documentation: - Rollkit acts as the consensus and data availability layer. - The execution layer (Cosmos SDK app or Reth) processes transactions and maintains application state. - For more details on integrating an execution layer with Rollkit, see the respective documentation links above. From be4ddcdcb650bd2239e9389bdba242c650b6bc43 Mon Sep 17 00:00:00 2001 From: Pierrick <9058370+pthmas@users.noreply.github.com> Date: Wed, 16 Jul 2025 14:51:11 +0200 Subject: [PATCH 19/19] Update learn/execution.md Co-authored-by: Marko --- learn/execution.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/learn/execution.md b/learn/execution.md index 996a4d9b1..9f3d42721 100644 --- a/learn/execution.md +++ b/learn/execution.md @@ -25,7 +25,7 @@ For more information about Reth, see the official documentation: ## How It Works -- Rollkit acts as the consensus and data availability layer. +- Rollkit acts as the consensus and uses Celestia as its data availability layer. - The execution layer (Cosmos SDK app or Reth) processes transactions and maintains application state. For more details on integrating an execution layer with Rollkit, see the respective documentation links above.