gossipsub partial messages extension: Avoid sending update message that could be inferred.
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 1.8k
- Forks
- 320
- Avg merge
- 11d 15h
- Merged PRs (30d)
- 1
Description
Consider this simple example:
A message has three parts and there are two nodes A and B. Node A has the first part and node B has all parts. They exchange the following messages.
Node A sends partsMetadata = 100 to Node B.
Node B responds with the second part (and its partsMetadata = 111)
Node A sends Node B partsMetadata = 111.
Notice that the last message is not necessary. Node B knows it has given the second part to node A. Node B can infer that Node A's partsMetadata will be 111 when it receives the message.
Node A tracks its peer's view of its own partsMetadata and SHOULD send updates when that view is incorrect.
In the above case Node A should know that Node B has updated its view of A's partsMetadata to be 111 and thus not need to send an update.
This should work whether the validation of a message part is async or not. It should work if A got part 2 from another peer and have an updated partsMetadata of 110. "Should work" is short hand for "Peer A should not send a updated partsMetadata to Peer B".
There are different solutions to this problem, but I'd like to focus on solutions that don't involve changes to the protocol messages (e.g. adding more data in messages). I'll follow up here with one possible solution.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the gossipsub partial-messages specification and the message-exchange examples in this issue. Examine how peer views are tracked for synchronous and asynchronous validation, including parts received from another peer. Done means a protocol-preserving design and specification changes demonstrate that redundant partsMetadata updates are not sent in these cases.
Written by the indexing model from the issue text.
Assessment
- Domain
- distributed-systems, networking
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100