-
Notifications
You must be signed in to change notification settings - Fork 668
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Validator Gossiper #2015
Add Validator Gossiper #2015
Conversation
5219416
to
8119600
Compare
} | ||
|
||
func (v ValidatorGossiper) Gossip(ctx context.Context) error { | ||
if !v.Validators.Has(ctx, v.NodeID) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This does not interfere with push gossip that may otherwise be going on, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The bloom filter gossip stuff is sandboxed in its own implementation so it runs in parallel to the existing push gossip. The push gossip stuff also doesn't implement the Gossiper
interface so it shouldn't ever be affected by this.
Why this should be merged
We currently throttle inbound requests for our tx gossip, so it doesn't make sense for us to request gossip if we're not a current validator.
How this works
Gossiper
toPullGossiper
Gossiper
interface since we now have multipleGossiper
implementations.ValidatorGossiper
that only gossips if we are a valdiator.How this was tested
Added a unit test