Add newly completed slots signal to Blocktree (#4225)

* Add channel to blocktree for communicating when slots are completed

* Refactor RepairService options into a RepairStrategy
This commit is contained in:
carllin
2019-05-09 14:10:04 -07:00
committed by GitHub
parent a031b09190
commit 575a0e318b
8 changed files with 289 additions and 71 deletions

View File

@ -83,8 +83,14 @@ fn test_replay() {
let tvu_addr = target1.info.tvu;
let (bank_forks, _bank_forks_info, blocktree, ledger_signal_receiver, leader_schedule_cache) =
fullnode::new_banks_from_blocktree(&blocktree_path, None);
let (
bank_forks,
_bank_forks_info,
blocktree,
ledger_signal_receiver,
completed_slots_receiver,
leader_schedule_cache,
) = fullnode::new_banks_from_blocktree(&blocktree_path, None);
let working_bank = bank_forks.working_bank();
assert_eq!(
working_bank.get_balance(&mint_keypair.pubkey()),
@ -126,6 +132,7 @@ fn test_replay() {
&leader_schedule_cache,
&exit,
&solana_sdk::hash::Hash::default(),
completed_slots_receiver,
);
let mut mint_ref_balance = mint_balance;