Skip to content

Commit

Permalink
WIP:
Browse files Browse the repository at this point in the history
  • Loading branch information
dkuanyshbaev committed Nov 13, 2024
1 parent 566d4fa commit 94c36bc
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
19 changes: 18 additions & 1 deletion node/service/src/dev.rs
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,13 @@ where
other: (rpc_builder, block_import, grandpa_link, mut telemetry),
} = new_partial(&config)?;

let mut net_config = sc_network::config::FullNetworkConfiguration::new(&config.network);
let mut net_config = sc_network::config::FullNetworkConfiguration::new(
&config.network,
config
.prometheus_config
.as_ref()
.map(|cfg| cfg.registry.clone()),
);

let grandpa_protocol_name = sc_consensus_grandpa::protocol_standard_name(
&client
Expand All @@ -277,6 +283,17 @@ where
.expect("Genesis block exists; qed"),
&config.chain_spec,
);
// let metrics = Network::register_notification_metrics(
// config.prometheus_config.as_ref().map(|cfg| &cfg.registry),
// );
// let peer_store_handle = net_config.peer_store_handle();
// let (grandpa_protocol_config, grandpa_notification_service) =
// sc_consensus_grandpa::grandpa_peers_set_config(
// grandpa_protocol_name.clone(),
// metrics.clone(),
// Arc::clone(&peer_store_handle),
// );
// net_config.add_notification_protocol(grandpa_protocol_config);
net_config.add_notification_protocol(sc_consensus_grandpa::grandpa_peers_set_config(
grandpa_protocol_name.clone(),
));
Expand Down
4 changes: 2 additions & 2 deletions node/service/src/parachain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ use cumulus_primitives_core::ParaId;
use cumulus_primitives_parachain_inherent::ParachainInherentData;
use cumulus_relay_chain_interface::RelayChainInterface;
use parity_scale_codec::Encode;
use robonomics_primitives::{AccountId, Balance, Block, Nonce};
use robonomics_primitives::{AccountId, Balance, Block, Hash, Nonce};

use sc_consensus::ImportQueue;
use sc_executor::{HeapAllocStrategy, WasmExecutor, DEFAULT_HEAP_ALLOC_STRATEGY};
Expand Down Expand Up @@ -369,7 +369,7 @@ where
let import_queue_service = params.import_queue.service();

// let net_config = FullNetworkConfiguration::new(&parachain_config.network);
let mut net_config = FullNetworkConfiguration::<_, _, Network>::new(
let net_config = FullNetworkConfiguration::<_, _, sc_network::NetworkWorker<Block, Hash>>::new(
&parachain_config.network,
parachain_config
.prometheus_config
Expand Down

0 comments on commit 94c36bc

Please sign in to comment.