libp2p / libp2p/go-libp2p

Peer dialing to self

Open
#328 21 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

kind/support
Dominant language
Go
Stars
6.9k
Forks
1.3k
Avg merge
13d 21h
Merged PRs (30d)
1

Description

Is it do-able to enable peers to dial themselves?

We have Raft using a libp2p-transport and it wants to dial itself all the time. It does not seem to cause undesired side-effects, but it does not seem crazy that any cluster-application using RPCs ends up trying to contact itself for some things. (same issue in ipfs-cluster RPC, but we worked around it).

Perhaps we can provide some shortcut at a higher level so that a peer contacting itself does not even attempt touch the network?

Pointers appreciated...

Contributor guide

No contributing guide indexed for this repository

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 by tracing the libp2p peer-dialing entry point and how a local peer identity is handled by the transport. Compare the Raft and ipfs-cluster self-dial use cases described in the issue, then determine the appropriate higher-level behavior and tests needed to verify that self-connections avoid unnecessary network activity.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
networking
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.