Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Reduce consensus gossip spam #1538

Merged
merged 4 commits into from
Jan 23, 2019
Merged

Conversation

andresilva
Copy link
Contributor

  • Only broadcast grandpa messages if the node is an authority in the current set
  • Keep known consensus gossip messages for twice their expiration time

@andresilva andresilva added A0-please_review Pull request needs code review. M4-core labels Jan 23, 2019
@@ -1524,6 +1533,7 @@ pub fn run_grandpa<B, E, Block: BlockT<Hash=H256>, N, RA>(
);

let committer_data = committer_communication(
config.local_key.clone(),
Copy link
Contributor

Choose a reason for hiding this comment

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

we might rather want to move the logic for checking if we are a current voter to just above this function call. Then the outgoing_messages for every round will also be a no-op.

config.local_key = config.local_key.filter(|pair| voters.contains_key(&pair.public().into()))

@gavofyork gavofyork merged commit f608158 into master Jan 23, 2019
@gavofyork gavofyork deleted the andre/reduce-consensus-gossip-spam branch January 23, 2019 22:12
rphmeier pushed a commit that referenced this pull request Jan 23, 2019
* core: keep known gossip messages for twice their expiration

* core: test expiration of known gossip messages

* core: only broadcast grandpa votes if authority in current set

* core: only broadcast grandpa commits if authority in current set
rphmeier pushed a commit that referenced this pull request Jan 27, 2019
* core: keep known gossip messages for twice their expiration

* core: test expiration of known gossip messages

* core: only broadcast grandpa votes if authority in current set

* core: only broadcast grandpa commits if authority in current set
MTDK1 pushed a commit to bdevux/substrate that referenced this pull request Apr 12, 2019
* core: keep known gossip messages for twice their expiration

* core: test expiration of known gossip messages

* core: only broadcast grandpa votes if authority in current set

* core: only broadcast grandpa commits if authority in current set
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants