Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 4 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
9 changes: 9 additions & 0 deletions node/network/protocol/src/peer_set.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,17 @@ impl PeerSet {
/// network service.
pub fn get_info(self) -> NonDefaultSetConfig {
let protocol = self.into_protocol_name();
let max_notification_size = match self {
PeerSet::Validation => 1024 * 1024,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PoV are also sent on the ValidationProtocol, so message limits should be the same IMO

// TODO: lower this limit after https://github.com/paritytech/polkadot/issues/2283 is
// done and collations use request-response protocols
PeerSet::Collation => 16 * 1024 * 1024,
};

match self {
PeerSet::Validation => NonDefaultSetConfig {
notifications_protocol: protocol,
max_notification_size,
set_config: sc_network::config::SetConfig {
in_peers: 25,
out_peers: 0,
Expand All @@ -48,6 +56,7 @@ impl PeerSet {
},
PeerSet::Collation => NonDefaultSetConfig {
notifications_protocol: protocol,
max_notification_size,
set_config: SetConfig {
in_peers: 25,
out_peers: 0,
Expand Down