mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-11 18:04:18 +00:00
@@ -214,6 +214,7 @@ impl<T: BeaconChainTypes> BlockLookups<T> {
|
||||
/// Check if this new lookup extends a bad chain:
|
||||
/// - Extending `child_block_root_trigger` would exceed the max depth
|
||||
/// - `block_root_to_search` is a failed chain
|
||||
///
|
||||
/// Returns true if the lookup is created or already exists
|
||||
pub fn search_parent_of_child(
|
||||
&mut self,
|
||||
|
||||
@@ -448,12 +448,12 @@ impl<T: BeaconChainTypes> SyncManager<T> {
|
||||
///
|
||||
/// The logic for which sync should be running is as follows:
|
||||
/// - If there is a range-sync running (or required) pause any backfill and let range-sync
|
||||
/// complete.
|
||||
/// complete.
|
||||
/// - If there is no current range sync, check for any requirement to backfill and either
|
||||
/// start/resume a backfill sync if required. The global state will be BackFillSync if a
|
||||
/// backfill sync is running.
|
||||
/// start/resume a backfill sync if required. The global state will be BackFillSync if a
|
||||
/// backfill sync is running.
|
||||
/// - If there is no range sync and no required backfill and we have synced up to the currently
|
||||
/// known peers, we consider ourselves synced.
|
||||
/// known peers, we consider ourselves synced.
|
||||
fn update_sync_state(&mut self) {
|
||||
let new_state: SyncState = match self.range_sync.state() {
|
||||
Err(e) => {
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//! - Only one finalized chain can sync at a time
|
||||
//! - The finalized chain with the largest peer pool takes priority.
|
||||
//! - As one finalized chain completes, others are checked to see if we they can be continued,
|
||||
//! otherwise they are removed.
|
||||
//! otherwise they are removed.
|
||||
//!
|
||||
//! ## Head Chain Sync
|
||||
//!
|
||||
|
||||
Reference in New Issue
Block a user