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

Peers: assigning nicknames / pet names #1018

Open
sehejkaw opened this issue Apr 23, 2019 · 8 comments
Open

Peers: assigning nicknames / pet names #1018

sehejkaw opened this issue Apr 23, 2019 · 8 comments
Labels
effort/days Estimated to take multiple days, but less than a week exp/intermediate Prior experience is likely helpful kind/enhancement A net-new feature or improvement to an existing feature need/analysis Needs further analysis before proceeding need/maintainers-input Needs input from the current maintainer(s) P3 Low: Not priority right now status/blocked Unable to be worked further until needs are met topic/design-ux UX strategy, research, not solely visual design

Comments

@sehejkaw
Copy link

A peer nickname can be added next to peer ID.

@jessicaschilling
Copy link
Contributor

@lidel @olizilla and others -- thoughts on feasibility/desirability here? Marking as an issue for discussion for now.

@jessicaschilling jessicaschilling added exp/intermediate Prior experience is likely helpful effort/days Estimated to take multiple days, but less than a week kind/enhancement A net-new feature or improvement to an existing feature need/analysis Needs further analysis before proceeding need/maintainers-input Needs input from the current maintainer(s) P3 Low: Not priority right now status/inactive No significant work in the previous month topic/design-ux UX strategy, research, not solely visual design labels Apr 2, 2020
@lidel
Copy link
Member

lidel commented Apr 7, 2020

The idea of "pet names" was part of #891 but only "Add connection" button was added to the Peers screen. Labeling peers was descoped because while we could implement it in userland (store names in local storage of webui Origin), the names would show only in webui.

I believe a better way is to add support for this to ipfs swarm * commands and persist them as additional metadata in peerstore that could be read on-demand, similar to existing --direction:

$ ipfs swarm connect --petname PeeryMcPeer /p2p/QmPeerId
connect QmPeerId success

$ ipfs swarm peers --petname

/ipv4/somethingelse  OtherNick
/ipv4/no-petname  
/ipv4/something      PeeryMcPeer

That way we can not only support them in webui, but also CLI, RPC API and other tools.

cc @vasco-santos (from libp2p) if libp2p project discussed adding this type of metadata before

@lidel lidel changed the title Addition of nickname Peers: assigning nicknames / pet names Apr 7, 2020
@vasco-santos
Copy link
Member

Hey folks!

I am currently working on improving libp2p's PeerStore on JS land and this is one of the things that I intend to support. By the end of the PeerStore improvements, we should support adding metadata to a peer.

Regarding API for libp2p and IPFS, we did not start discussing this yet, since my main focus has been the AddressBook, ProtoBook and KeyBook. As soon as we have the former books, I will be working on the MetadataBook, which should be used for this use case. I will keep you posted and we can discuss further this API

@vasco-santos
Copy link
Member

vasco-santos commented May 4, 2020

PSA: I wrote my initial thoughts on the MetadataBook for js-libp2p. Depending on the feedback, this might get into the next js-libp2p release work: libp2p/js-libp2p#627

@jessicaschilling
Copy link
Contributor

@vasco-santos - what's the latest status of this? Thanks!

@vasco-santos
Copy link
Member

vasco-santos commented Aug 21, 2020

Hey!
@jessicaschilling well, it is shipped in libp2p, you can add data to the metadatabook as described in the API doc. There is no friendly API in the IPFS side of things so far, like the examples @lidel wrote above.
For now you can use that feature by doing ipfs.libp2p.peerStore* through the API (no CLI support). You can use .peers to access all the peers if you want to do a "filter" per a specific metadata key later on. This is supported from ipfs@0.47 IIRC

@jessicaschilling
Copy link
Contributor

Thanks, @vasco-santos!

@lidel - given the current status, do you think this is something that's worth putting out for bounty right now?

@lidel
Copy link
Member

lidel commented Aug 25, 2020

This is blocked until high level API support for peerstore metadata is present in both js-ipfs and go-ipfs (like #1018 (comment) or even more generic kv approach).

@lidel lidel added status/blocked Unable to be worked further until needs are met and removed status/inactive No significant work in the previous month labels Aug 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
effort/days Estimated to take multiple days, but less than a week exp/intermediate Prior experience is likely helpful kind/enhancement A net-new feature or improvement to an existing feature need/analysis Needs further analysis before proceeding need/maintainers-input Needs input from the current maintainer(s) P3 Low: Not priority right now status/blocked Unable to be worked further until needs are met topic/design-ux UX strategy, research, not solely visual design
Projects
No open projects
Status: Needs Grooming
Development

No branches or pull requests

4 participants