Skip to content
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions crates/app/src/node/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,16 @@ async fn run(config: AppConfig, ct: CancellationToken) -> Result<(), AppError> {
let peers = lock.peers()?;
pluto_p2p::peer::verify_p2p_key(&peers, &key)?;

// Tracker view of the cluster, captured before `peers` moves into the P2P
// wiring. Share indices are 1-indexed, matching partial-signature share ids.
let tracker_peers: Vec<pluto_core::tracker::PeerInfo> = peers
.iter()
.map(|peer| pluto_core::tracker::PeerInfo {
name: peer.name.clone(),
share_idx: usize::try_from(peer.index.saturating_add(1)).unwrap_or(usize::MAX),
})
.collect();

// Cluster size + quorum for the health-checker metadata, captured before
// `peers` is moved into the P2P wiring.
let num_peers = i64::try_from(peers.len()).unwrap_or(i64::MAX);
Expand Down Expand Up @@ -547,6 +557,8 @@ async fn run(config: AppConfig, ct: CancellationToken) -> Result<(), AppError> {
fetch_only_comm_idx0,
seen_pubkeys: Some(seen_pubkeys_observer),
slot_tick: vmock.clone().map(|v| simnet_slot_tick(v, ct.clone())),
peers: tracker_peers,
feature_set: Arc::clone(&feature_set),
},
ct.clone(),
)
Expand Down
Loading
Loading