-
Notifications
You must be signed in to change notification settings - Fork 72
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
Libp2p endpoint that lists supported transport protocols #717
Comments
can endpoint be a multiaddr? we have ways to encode http endpoints as multiaddrs e.g. https://github.com/filecoin-project/go-legs/blob/main/httpsync/multiaddr/convert.go |
I'm not sure there's an advantage to forcing multiaddr encoding - if the endpoint for HTTP is a multiaddr you will just need to convert it to an HTTP URL to use it (and in future there may be transports that aren't encodable as multiaddr) |
Philosophically it's about using our stack where it doesn't hurt us to do so. this seems like a place where that's true, and it means we could add additional metadata into multiaddr clients without worrying about breaking parsers. |
Could you expand on that, what kind of metadata are you thinking about? The counter-case is that if in future we add support for retrieval protocols that are not supported by multiaddr then we will have clients in the wild who will error out when reading the response from this endpoint. |
I get that everything serializes to strings, but multiaddrs are supposed to be the extensible type for this. |
things i could imagine wanting to tag, which could be done in a backwards-compatible way by adding them as extra segments in the multiaddrs include:
|
Ok seems reasonable 👍 |
Goals
Storage Providers now support protocols beyond libp2p for retrieval. It should be possible for a client to query a SP to ask which protocols it supports, and what is the endpoint for the protocol.
Description
Expose a new libp2p endpoint that returns supported protocols and the endpoint for the protocol, eg
Endpoint
The endpoint is at
/fil/retrieval/transports
Note that an SP typically listens on these libp2p endpoints:
Schema
The text was updated successfully, but these errors were encountered: