Skip to content

Conversation

@aarshkshah1992
Copy link
Contributor

For #217 as enlisted in #220

Low hanging fruit :) The other tasks enlisted in #217 will be next.

@Stebalien Stebalien requested a review from vyzo November 15, 2019 17:24
pubsub.go Outdated
// We start dropping messages to a peer if the outbound queue if full
func WithPeerOutboundQueueSize(size int) Option {
return func(p *PubSub) error {
if size < 0 {
Copy link
Collaborator

Choose a reason for hiding this comment

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

It can't be zero either.

Copy link
Contributor Author

@aarshkshah1992 aarshkshah1992 Nov 15, 2019

Choose a reason for hiding this comment

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

I see what you mean. Because we write the HelloPacket to the queue before we start the go-routine that reads from it & dispatches it. Thanks for pointing this out.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@vyzo Have addressed this. Let me know if you have any concerns before we merge this.

Copy link
Collaborator

@vyzo vyzo left a comment

Choose a reason for hiding this comment

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

LGTM

@vyzo vyzo merged commit 323a411 into libp2p:master Nov 15, 2019
pdyraga added a commit to threshold-network/keep-core that referenced this pull request Jan 20, 2020
This version will let us set peer peer outbound queue size to avoid
problems with messages dropped when this queue is full during DKG.

libp2p/go-libp2p-pubsub#230
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants