Skip to content

feat: implement gossipsub partial messages extension#577

Closed
jxs wants to merge 94 commits intosigp:masterfrom
jxs:gossipsub-partial-messages
Closed

feat: implement gossipsub partial messages extension#577
jxs wants to merge 94 commits intosigp:masterfrom
jxs:gossipsub-partial-messages

Conversation

@jxs
Copy link
Copy Markdown
Member

@jxs jxs commented Sep 16, 2025

Description

This is a draft implementation of partial messages for gossipsub following the spec PR and based on the Go implementation. Still WIP but should give a good idea of the direction we're heading.

jxs added 10 commits September 9, 2025 10:48
This started with an attempt to solve libp2p#5751 using the previous internal async-channel.
After multiple ideas were discussed off band, replacing the async-channel with an internal more tailored priority queue seemed inevitable.
This priority queue allows us to implement the cancellation of in flight IDONTWANT's very cleanly with the remove_data_messages function.
Clearing the stale messages likewise becomes simpler as we also make use of remove_data_messages
And this has the added advantage of being able to only have a single priority queue and making the code simpler.
If a peer is not making progress we can assume it's not delivering High priority messages and we can penalize it.
Comment thread protocols/gossipsub/src/behaviour.rs Outdated
Comment thread protocols/gossipsub/src/behaviour.rs Outdated
Comment thread protocols/gossipsub/src/types.rs Outdated
@jxs jxs force-pushed the gossipsub-partial-messages branch 5 times, most recently from cb0e925 to e6f1ae4 Compare September 26, 2025 11:35
@jxs jxs force-pushed the gossipsub-partial-messages branch from e6f1ae4 to 69c2d95 Compare September 26, 2025 14:24
@jxs jxs force-pushed the gossipsub-partial-messages branch from 28f528d to 01b63ba Compare February 17, 2026 18:51
@jxs jxs changed the base branch from sigp-gossipsub to master February 18, 2026 09:54
@jxs jxs force-pushed the gossipsub-partial-messages branch from fb46f1f to ffd4c98 Compare February 18, 2026 09:59
jxs added 4 commits February 18, 2026 10:36
Add extra metrics for recording bytes sent and received on each topic.
This will be helpful for a future PR implementing the [partial messages spec](libp2p/specs#685)

Pull-Request: libp2p#6192.
@jxs jxs force-pushed the gossipsub-partial-messages branch from ffd4c98 to bf1d6d7 Compare February 18, 2026 12:34
@jxs jxs force-pushed the gossipsub-partial-messages branch from d995b3c to a39b9b2 Compare February 18, 2026 15:07
Comment thread xterm-ghostty Outdated
Comment thread protocols/gossipsub/src/config.rs Outdated
Comment thread protocols/gossipsub/src/extensions/partial_messages.rs Outdated
Comment thread protocols/gossipsub/src/extensions/partial_messages.rs Outdated
@jxs jxs force-pushed the gossipsub-partial-messages branch 5 times, most recently from 38d449b to a03aa97 Compare February 20, 2026 17:54
@jxs jxs force-pushed the gossipsub-partial-messages branch from a03aa97 to 452e857 Compare February 20, 2026 18:00
@jxs
Copy link
Copy Markdown
Member Author

jxs commented Feb 20, 2026

closing this in favor of libp2p#6275

@jxs jxs closed this Feb 20, 2026
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.

4 participants