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(rollup): add support for unsafe heads in rollup::Driver (with op_net::NetworkDriver) #99

Open
merklefruit opened this issue Sep 22, 2024 · 0 comments
Labels
A-rollup Area: rollup crate C-enhancement New feature or request

Comments

@merklefruit
Copy link
Collaborator

Adding the unsafe heads channel will enable Hera to follow the rollup chain directly from the sequencer feed instead of having to wait for safe heads to be available on L1.

As part of this task, a few design decisiona need to be made:

  • where should the NetworkDriver live? how do we communicate with it?
    • Right now I believe it can just be left running in an independent tokio task and it'll be fine.
    • Long term we'll probably add a NetworkHandle if we ever need to send commands to the Network actor.
    • For now, the only thing we need to do is receive blocks from the unsafe blocks channel.
    • We don't immediately need to care about where the NetworkDriver is spawned I think.
  • where do we keep track of the unsafe / safe state?
    • ideally the rollup::Driver should have new fields to do this, e.g. unsafe_head, safe_head and finalized_head
    • we may want to put these in something like a HeadState struct? (not sure)
  • the Driver needs to be able to roll back on unsafe heads if it detects a l2 reorg
    • for safe heads we rely on the RollupPipeline to perform the reset
    • at this stage we don't need to care about sending the right engine API messages (TBD, different task)
  • how do unsafe & safe heads interact?

& more that'll come up just trying to implement this.

@merklefruit merklefruit added C-enhancement New feature or request A-rollup Area: rollup crate labels Sep 22, 2024
@merklefruit merklefruit changed the title feat(rollup): integrate NetworkDriver into rollup::Driver to receive unsafe heads feat(rollup): add support for unsafe heads in rollup::Driver (with op_net::NetworkDriver) Sep 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rollup Area: rollup crate C-enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant