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

Bitswap peer receives duplicate blocks #261

Closed
btc opened this issue Nov 3, 2014 · 4 comments
Closed

Bitswap peer receives duplicate blocks #261

btc opened this issue Nov 3, 2014 · 4 comments
Assignees
Labels
kind/enhancement A net-new feature or improvement to an existing feature status/in-progress In progress

Comments

@btc
Copy link
Contributor

btc commented Nov 3, 2014

@whyrusleeping performed a bitswap test.

  1. Three nodes pin a widely available file.
  2. Each node receives multiple copies of the file. (In his test, each received 20. Every partner that received the three nodes' want lists sent every block on it)

Some initial discussion occurred in IRC at #ipfs. Let's open discussion around the implementation of solutions for the various inefficiencies of the current implementation. Empirical and analytical approaches are both welcome.

A couple initial idea come to mind:

  • Instead of sending requests to each and every block provider (returned from the routing system), schedule requests to a small number and follow up with additional requests if necessary
  • Instead of sending the local node's entire want list to each and every peer, partition the want list.

edited: with additional info from @whyrusleeping

cc
@danmane

@btc btc added the kind/enhancement A net-new feature or improvement to an existing feature label Nov 3, 2014
@whyrusleeping
Copy link
Member

Essentially what it came down to is that everyone who got out want list sent us every block on it. That's probably not good

@whyrusleeping
Copy link
Member

Also, Since this issue is titled "Bitswap Improvements" I figure its a fair place to mention that i feel the strategies are too tightly coupled with the ledgers. I feel like the strategies should be a simpler function (or method on an object) that is passed a ledger as its state.

@btc
Copy link
Contributor Author

btc commented Nov 4, 2014

@whyrusleeping

Thinking of the ledger as per-peer bitswap state... if we wish to strategize on a per-peer basis, information about the active strategy for the peer must reside within that state.

We could remove the StrategyFunc, but the ledger would still need a StrategyId. Would that assuage your concern? If yes, then I'm in agreement. If not, then we might be on different pages and I'm curious what you have in mind.

@btc btc changed the title Bitswap Improvements Bitswap peer receives duplicate blocks Nov 8, 2014
@btc btc added the status/in-progress In progress label Nov 24, 2014
@whyrusleeping
Copy link
Member

Im pretty sure i can mark this resolved, the latest changeset to bitswap has partially addressed this. (still not perfect, but better)

@Stebalien Stebalien mentioned this issue May 26, 2020
77 tasks
ariescodescream pushed a commit to ariescodescream/go-ipfs that referenced this issue Oct 23, 2021
@ajnavarro ajnavarro mentioned this issue Aug 24, 2022
72 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement A net-new feature or improvement to an existing feature status/in-progress In progress
Projects
None yet
Development

No branches or pull requests

2 participants