fix bootstrap without known validators (#25293)
This commit is contained in:
parent
5548baf4dd
commit
24122768da
|
@ -1114,14 +1114,15 @@ mod with_incremental_snapshots {
|
|||
validator_config: &ValidatorConfig,
|
||||
rpc_peers: &[ContactInfo],
|
||||
) -> Vec<PeerSnapshotHash> {
|
||||
let mut peer_snapshot_hashes = get_eligible_peer_snapshot_hashes(cluster_info, rpc_peers);
|
||||
if validator_config.known_validators.is_some() {
|
||||
let known_snapshot_hashes =
|
||||
get_snapshot_hashes_from_known_validators(cluster_info, validator_config);
|
||||
|
||||
let mut peer_snapshot_hashes = get_eligible_peer_snapshot_hashes(cluster_info, rpc_peers);
|
||||
retain_peer_snapshot_hashes_that_match_known_snapshot_hashes(
|
||||
&known_snapshot_hashes,
|
||||
&mut peer_snapshot_hashes,
|
||||
);
|
||||
}
|
||||
retain_peer_snapshot_hashes_with_highest_full_snapshot_slot(&mut peer_snapshot_hashes);
|
||||
retain_peer_snapshot_hashes_with_highest_incremental_snapshot_slot(
|
||||
&mut peer_snapshot_hashes,
|
||||
|
|
Loading…
Reference in New Issue