mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-04-08 03:01:12 -04:00
docs(rpc): add docs about engine_getPayloadV build process cancel (#2187)
This commit is contained in:
@@ -37,11 +37,21 @@ pub trait EngineApi {
|
||||
|
||||
/// See also <https://github.com/ethereum/execution-apis/blob/6709c2a795b707202e93c4f2867fa0bf2640a84f/src/engine/paris.md#engine_getpayloadv1>
|
||||
///
|
||||
/// Returns the most recent version of the payload that is available in the corresponding
|
||||
/// payload build process at the time of receiving this call.
|
||||
///
|
||||
/// Caution: This should not return the `withdrawals` field
|
||||
///
|
||||
/// Note:
|
||||
/// > Client software MAY stop the corresponding build process after serving this call.
|
||||
#[method(name = "engine_getPayloadV1")]
|
||||
async fn get_payload_v1(&self, payload_id: PayloadId) -> Result<ExecutionPayload>;
|
||||
|
||||
/// See also <https://github.com/ethereum/execution-apis/blob/6709c2a795b707202e93c4f2867fa0bf2640a84f/src/engine/shanghai.md#engine_getpayloadv2>
|
||||
///
|
||||
/// Returns the most recent version of the payload that is available in the corresponding
|
||||
/// payload build process at the time of receiving this call. Note:
|
||||
/// > Client software MAY stop the corresponding build process after serving this call.
|
||||
#[method(name = "engine_getPayloadV2")]
|
||||
async fn get_payload_v2(&self, payload_id: PayloadId) -> Result<ExecutionPayloadEnvelope>;
|
||||
|
||||
|
||||
@@ -152,9 +152,16 @@ impl EngineApiServer for EngineApi {
|
||||
}
|
||||
|
||||
/// Handler for `engine_getPayloadV1`
|
||||
///
|
||||
/// Returns the most recent version of the payload that is available in the corresponding
|
||||
/// payload build process at the time of receiving this call.
|
||||
///
|
||||
/// See also <https://github.com/ethereum/execution-apis/blob/8db51dcd2f4bdfbd9ad6e4a7560aac97010ad063/src/engine/specification.md#engine_getPayloadV1>
|
||||
///
|
||||
/// Caution: This should not return the `withdrawals` field
|
||||
///
|
||||
/// Note:
|
||||
/// > Client software MAY stop the corresponding build process after serving this call.
|
||||
async fn get_payload_v1(&self, payload_id: PayloadId) -> Result<ExecutionPayload> {
|
||||
let (tx, rx) = oneshot::channel();
|
||||
self.delegate_request(EngineApiMessage::GetPayload(payload_id, tx), rx)
|
||||
@@ -163,7 +170,14 @@ impl EngineApiServer for EngineApi {
|
||||
}
|
||||
|
||||
/// Handler for `engine_getPayloadV2`
|
||||
///
|
||||
/// Returns the most recent version of the payload that is available in the corresponding
|
||||
/// payload build process at the time of receiving this call.
|
||||
///
|
||||
/// See also <https://github.com/ethereum/execution-apis/blob/main/src/engine/specification.md#engine_getpayloadv2>
|
||||
///
|
||||
/// Note:
|
||||
/// > Client software MAY stop the corresponding build process after serving this call.
|
||||
async fn get_payload_v2(&self, payload_id: PayloadId) -> Result<ExecutionPayloadEnvelope> {
|
||||
let (tx, rx) = oneshot::channel();
|
||||
self.delegate_request(EngineApiMessage::GetPayload(payload_id, tx), rx).await
|
||||
|
||||
Reference in New Issue
Block a user