mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-02-17 18:31:42 -05:00
feat(sync): beacon consensus engine (#1845)
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
use crate::EngineApiSender;
|
||||
use reth_beacon_consensus::BeaconEngineSender;
|
||||
use reth_interfaces::consensus::ForkchoiceState;
|
||||
use reth_primitives::{BlockHash, BlockNumber, H64};
|
||||
use reth_rpc_types::engine::{
|
||||
@@ -9,26 +10,25 @@ use reth_rpc_types::engine::{
|
||||
/// Message type for communicating with [`EngineApi`][crate::EngineApi].
|
||||
#[derive(Debug)]
|
||||
pub enum EngineApiMessage {
|
||||
/// New payload message
|
||||
NewPayload(EngineApiMessageVersion, ExecutionPayload, EngineApiSender<PayloadStatus>),
|
||||
/// Get payload message
|
||||
GetPayload(H64, EngineApiSender<ExecutionPayload>),
|
||||
/// Get payload bodies by range message
|
||||
GetPayloadBodiesByRange(BlockNumber, u64, EngineApiSender<ExecutionPayloadBodies>),
|
||||
/// Get payload bodies by hash message
|
||||
GetPayloadBodiesByHash(Vec<BlockHash>, EngineApiSender<ExecutionPayloadBodies>),
|
||||
/// Forkchoice updated message
|
||||
ForkchoiceUpdated(
|
||||
EngineApiMessageVersion,
|
||||
ForkchoiceState,
|
||||
Option<PayloadAttributes>,
|
||||
EngineApiSender<ForkchoiceUpdated>,
|
||||
),
|
||||
/// Exchange transition configuration message
|
||||
ExchangeTransitionConfiguration(
|
||||
TransitionConfiguration,
|
||||
EngineApiSender<TransitionConfiguration>,
|
||||
),
|
||||
/// New payload message
|
||||
NewPayload(ExecutionPayload, BeaconEngineSender<PayloadStatus>),
|
||||
/// Forkchoice updated message
|
||||
ForkchoiceUpdated(
|
||||
ForkchoiceState,
|
||||
Option<PayloadAttributes>,
|
||||
BeaconEngineSender<ForkchoiceUpdated>,
|
||||
),
|
||||
}
|
||||
|
||||
/// The version of Engine API message.
|
||||
|
||||
Reference in New Issue
Block a user