mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-16 20:39:10 +00:00
Builder Specs v0.2.0 (#3134)
## Issue Addressed https://github.com/sigp/lighthouse/issues/3091 Extends https://github.com/sigp/lighthouse/pull/3062, adding pre-bellatrix block support on blinded endpoints and allowing the normal proposal flow (local payload construction) on blinded endpoints. This resulted in better fallback logic because the VC will not have to switch endpoints on failure in the BN <> Builder API, the BN can just fallback immediately and without repeating block processing that it shouldn't need to. We can also keep VC fallback from the VC<>BN API's blinded endpoint to full endpoint. ## Proposed Changes - Pre-bellatrix blocks on blinded endpoints - Add a new `PayloadCache` to the execution layer - Better fallback-from-builder logic ## Todos - [x] Remove VC transition logic - [x] Add logic to only enable builder flow after Merge transition finalization - [x] Tests - [x] Fix metrics - [x] Rustdocs Co-authored-by: Mac L <mjladson@pm.me> Co-authored-by: realbigsean <sean@sigmaprime.io>
This commit is contained in:
@@ -24,6 +24,16 @@ pub struct ChainConfig {
|
||||
///
|
||||
/// If set to 0 then block proposal will not wait for fork choice at all.
|
||||
pub fork_choice_before_proposal_timeout_ms: u64,
|
||||
/// Number of skip slots in a row before the BN refuses to use connected builders during payload construction.
|
||||
pub builder_fallback_skips: usize,
|
||||
/// Number of skip slots in the past `SLOTS_PER_EPOCH` before the BN refuses to use connected
|
||||
/// builders during payload construction.
|
||||
pub builder_fallback_skips_per_epoch: usize,
|
||||
/// Number of epochs since finalization before the BN refuses to use connected builders during
|
||||
/// payload construction.
|
||||
pub builder_fallback_epochs_since_finalization: usize,
|
||||
/// Whether any chain health checks should be considered when deciding whether to use the builder API.
|
||||
pub builder_fallback_disable_checks: bool,
|
||||
pub count_unrealized: bool,
|
||||
}
|
||||
|
||||
@@ -36,6 +46,11 @@ impl Default for ChainConfig {
|
||||
enable_lock_timeouts: true,
|
||||
max_network_size: 10 * 1_048_576, // 10M
|
||||
fork_choice_before_proposal_timeout_ms: DEFAULT_FORK_CHOICE_BEFORE_PROPOSAL_TIMEOUT,
|
||||
// Builder fallback configs that are set in `clap` will override these.
|
||||
builder_fallback_skips: 3,
|
||||
builder_fallback_skips_per_epoch: 8,
|
||||
builder_fallback_epochs_since_finalization: 3,
|
||||
builder_fallback_disable_checks: false,
|
||||
count_unrealized: false,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user