Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(kona-exex): Init Derivation Pipeline #8

Closed
refcell opened this issue Aug 22, 2024 · 0 comments · Fixed by #37
Closed

feat(kona-exex): Init Derivation Pipeline #8

refcell opened this issue Aug 22, 2024 · 0 comments · Fixed by #37
Assignees
Labels
A-hera Area: OP Stack Rollup node binary C-enhancement New feature or request

Comments

@refcell
Copy link
Collaborator

refcell commented Aug 22, 2024

Description

Issue #4 sets up the first part of the kona-exex, waiting on the L2 origin block.

This ticket is to initialize the derivation pipeline without setting up the main loop.

    /// Starts the Kona Execution Extension loop.
    pub async fn start(mut self) -> Result<()> {
		// Step 1: Wait for the L2 origin block to be available

		// Step 2: Initialize the Derivation Pipeline

		todo!("run the main loop")
    }

Reference: https://github.com/paradigmxyz/reth-exex-examples/pull/12/files#diff-fb2ecd571a8b660d914eac307e6aed9fc4fa610ad0b5521145d0fd6115e963dbR260-R292

Since the KonaExEx holds the providers to commit updates, initializing the derivation pipeline within KonaExEx is the most straightforward place.

use kona_derive::online::EthereumDataSource;
use super::types::{LocalPipeline, LocalAttributesBuilder, new_local_pipeline};

impl KonaExEx {
	...

    /// Initializes the derivation pipeline with the L2 origin block.
    pub async fn init_pipeline(&mut self, origin_l1_block: BlockInfo) -> LocalPipeline {
        let dap = EthereumDataSource::new(
            self.chain_provider.clone(),
            self.blob_provider.clone(),
            &self.cfg,
        );
        let attributes = LocalAttributesBuilder::new(
            self.cfg.clone(),
            self.l2_provider.clone(),
            self.chain_provider.clone(),
        );
        new_local_pipeline(
            self.cfg.clone(),
            self.chain_provider.clone(),
            self.l2_provider.clone(),
            dap,
            attributes,
            origin_l1_block,
        )
    }

	...
}
@shekhirin shekhirin added C-enhancement New feature or request A-hera Area: OP Stack Rollup node binary labels Aug 25, 2024
merklefruit added a commit that referenced this issue Aug 26, 2024
Adds an utility to create a `kona_derive::DerivationPipeline`
implementation suitable for the rollup node.
In particular, I tried to keep only the providers as generic, because
the actual stage implementations will
most likely be the same for the exex and the standalone mode.

addresses part of #8.
@merklefruit merklefruit self-assigned this Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-hera Area: OP Stack Rollup node binary C-enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants