Use BeefyParams (#3013)

This commit is contained in:
Andreas Doerr authored and GitHub committed 2021-05-12 14:03:48 +00:00
1 parent 32c21b6a6f
commit ea42f734dc
2 files changed
+16 -12

No files matched your search

+12 -8
View File
@@ -974,14 +974,18 @@ pub fn new_full<RuntimeApi, Executor>(
// We currently only run the BEEFY gadget on the Rococo and Wococo testnets.
if !disable_beefy && (chain_spec.is_rococo() || chain_spec.is_wococo()) {
let gadget = beefy_gadget::start_beefy_gadget::<_, beefy_primitives::ecdsa::AuthorityPair, _, _, _, _>(
client.clone(),
keystore_opt.clone(),
network.clone(),
beefy_link,
network.clone(),
if chain_spec.is_wococo() { 4 } else { 8 },
prometheus_registry.clone()
let beefy_params = beefy_gadget::BeefyParams {
client: client.clone(),
backend: backend.clone(),
key_store: keystore_opt.clone(),
network: network.clone(),
signed_commitment_sender: beefy_link,
min_block_delta: if chain_spec.is_wococo() { 4 } else { 8 },
prometheus_registry: prometheus_registry.clone(),
};
let gadget = beefy_gadget::start_beefy_gadget::<_, beefy_primitives::ecdsa::AuthorityPair, _, _, _>(
beefy_params
);
// Wococo's purpose is to be a testbed for BEEFY, so if it fails we'll