Skip to content
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

identify: remove support for Identify Delta #1975

Merged
merged 4 commits into from Jan 7, 2023

Conversation

marten-seemann
Copy link
Contributor

@marten-seemann marten-seemann commented Jan 3, 2023

Fixes #1974. Fixes #977.

-700 LOC, this is starting to pay off. We'll probably be able to shave off even more later.

Copy link
Member

@Stebalien Stebalien left a comment

Choose a reason for hiding this comment

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

Change looks good to me, but this probably needs a more in-depth review.

p2p/protocol/identify/id.go Outdated Show resolved Hide resolved
ids.Host.Peerstore().SetProtocols(p, mes.Protocols...)
if isPush {
ids.emitters.evtPeerProtocolsUpdated.Emit(event.EvtPeerProtocolsUpdated{
Copy link
Member

Choose a reason for hiding this comment

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

Hm. We should have been doing this all along...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes. A lot of libp2p users rely on this event, and Push is much more common than Delta.
My Kubo node receives 10x as many Push messages (see Grafana screenshot in #1974). I wonder how many subtle failures were caused by this...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Turns out we even had an issue for this: #977.

Copy link
Contributor

@MarcoPolo MarcoPolo left a comment

Choose a reason for hiding this comment

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

Nice work 🔥 🔥 🔥

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.

identify: remove support Delta Identify Push does not emit eventbus events
3 participants