client/network-gossip/bridge: Use bounded channel (#5748)
* client/network-gossip/bridge: Use bounded channel Instead of returning an unbounded channel on `GossipEngine::messages_for` return a bounded channel. For now the channel length is determined by the amount of past messages cached in the `ConsensusGossip`. With a bounded channel, one can't just fire-and-forget style send into it, but has to first check whether the channel is ready. Thus this commit restructures `GossipEngine::poll` and introduces a `ForwardingState` into `GossipEngine`. * client/network-gossip/bridge: Add quickcheck for different size channels
parent
80e4417f
Please register or sign in to comment