-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Open
Labels
A-op-rethRelated to Optimism and op-rethRelated to Optimism and op-rethA-sdkRelated to reth's use as a libraryRelated to reth's use as a libraryC-enhancementNew feature or requestNew feature or request
Description
Describe the feature
Currently, many teams are looking at pre-confirmations. Most solutions are variations of Flashblocks (e.g. Gattaca's Frags).
Rather than everyone recreating the wheel, I believe Reth would be the optimal place for a modular implementation.
The optimal modular solution would look as follows:
rblibfor custom payload building with Flashblocks when the sequencer builds blocks. The Flashbots team sees no reason this could be uncoupled from the Optimism payload types. This would be responsible for transmitting encoded flashblocks over websocket.- Reth for ingesting and serving flashblocks state. High level, this involves
- Decoding JSON bytes into the
FlashBlocktype. This is hardcoded toOpFlashblockPayloadwhich could be modularized. src - Inserting the Flashblock(s) into a pending sequence state src
- Pending Block Building, responsible for creating a
PendingFlashBlock. This seems fairly flexible already except requiringNextBlockEnvCtx: From<OpFlashblockPayloadBase>. I don't believe this is needed. src - Finally in the RPC layer, the
PendingFlashBlockis observed and state is read from the internalPendingBlock. Both of these types don't seem to be Optimism specific. src
- Decoding JSON bytes into the
Let me know if there's appetite for something like this and I can whip up a PR
Additional context
No response
lean-apple, karim-agha and julio4
Metadata
Metadata
Assignees
Labels
A-op-rethRelated to Optimism and op-rethRelated to Optimism and op-rethA-sdkRelated to reth's use as a libraryRelated to reth's use as a libraryC-enhancementNew feature or requestNew feature or request
Type
Projects
Status
Backlog