libp2p / libp2p/js-libp2p

libp2p http transport example

Open
#2,312 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

exp/intermediate help wanted kind/enhancement need/triage
Dominant language
TypeScript
Stars
2.6k
Forks
546
Avg merge
8h 18m
Merged PRs (30d)
16

Description

We should validate that we can utilize js-libp2p to fetch content from another libp2p node that supports an IPFS gateway over libp2p.

see https://github.com/ipfs/kubo/blob/master/docs/experimental-features.md#http-gateway-over-libp2p for more details.

  1. set up a kubo node and enable the http-gateway-over-libp2p experiment: ipfs config --json Experimental.GatewayOverLibp2p true
  2. load some known content into the kubo node's blockstore (because the experiment won't fetch remote content)
  3. create and register libp2p handler for /http/1.1 (I don't think one exists yet? the development of this example can be used when creating http over libp2p for js-libp2p) via components.registrar.register
  4. Ensure we can send an http request to that kubo node listening on the /http transport, and get a valid http response back.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Kubo experimental-features documentation for HTTP gateway over libp2p and the components.registrar.register entry point. Set up a Kubo node with the experiment enabled, load known content, and investigate the /http/1.1 handler described in the issue. Done means an HTTP request over the /http transport returns a valid response from the node.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
networking
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.