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

Config option for direct retrievals #267

Closed
aschmahmann opened this issue May 21, 2024 · 2 comments
Closed

Config option for direct retrievals #267

aschmahmann opened this issue May 21, 2024 · 2 comments
Assignees

Comments

@aschmahmann
Copy link
Contributor

The latest version enables direct retrieval from peers by default. This code path does a number of things that enable more work and complexity such as:

  • Delegated routing for provider and peer records
  • Connecting to these peers (and if libp2p peers) managing the connections
  • Filtering peers we can't talk to anyway
  • Caching so we don't keep trying to find addresses for peers we know we can't dial
  • etc.

While this is where we'd like to get to it'd be great to separately be able to debug the recursive-gateway vs direct retrieval cases and only switch on by default the features we're confident are going to work for most people (in this case recursive-gateways). This means this it'd be helpful to have an option in the config file to enable direct-retrievals that's currently off by default

@2color
Copy link
Member

2color commented May 24, 2024

Yeah this would be useful.

Relevant code lines for this:

  • Connecting to these peers (and if libp2p peers) managing the connections

One thing to note here is that only HTTP retrieval is enabled by default. Verified Fetch uses @helia/http by default. So while the delegated routing is called, it only acts on "transport-ipfs-gateway-http" responses.

@SgtPooki
Copy link
Member

SgtPooki commented Nov 4, 2024

This was completed with #391 and some subsequent PRs

@SgtPooki SgtPooki closed this as completed Nov 4, 2024
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

No branches or pull requests

3 participants