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

Better discovery and dialing heuristic #153

Closed
dirkmc opened this issue Nov 29, 2018 · 7 comments
Closed

Better discovery and dialing heuristic #153

dirkmc opened this issue Nov 29, 2018 · 7 comments
Assignees
Labels
bug Something isn't working enhancement New feature or request

Comments

@dirkmc
Copy link
Collaborator

dirkmc commented Nov 29, 2018

There are some issues with discovery:

  • It takes a long time for gossip to start up (around 15 seconds). This is because
  • We repeatedly dial the same peers
    This is because rendezvous repeatedly emits peer:connect (every 10s by default)
    3. I propose adding a wrapper around discovery that remembers which peers have been dialed
    I suggest the wrapper's memory should have a time limit, and a limit on the number of peers
  • Occasionally we do not dial on peer events, I think because of a bug in the dialing mechanism
    4. Implementing the wrapper should take care of this

I'm happy to work on a PR to fix these issues

@dirkmc
Copy link
Collaborator Author

dirkmc commented Nov 29, 2018

@pgte one thing I'm not sure about, what is the purpose of this block?

@victorb
Copy link
Contributor

victorb commented Nov 29, 2018

deploy in ipfs/infra#458)

Been deployed now

@dirkmc
Copy link
Collaborator Author

dirkmc commented Nov 29, 2018

@victorb wow you guys don't mess around :) Thanks!

@pgte
Copy link
Contributor

pgte commented Nov 30, 2018

@dirkmc this is great, thank you!
Trying to answer your question:
When trying to find if a peer is interested in the app, we need to make sure that he's in the inbound or outbound connection list, so that the connection accounting is correct.

(Thinking about this again, I'm not sure of why the peer would be in the inbound list if it wasn't in the peer ring, but I may be missing something...)

@pgte pgte added bug Something isn't working enhancement New feature or request labels Nov 30, 2018
@dirkmc
Copy link
Collaborator Author

dirkmc commented Dec 3, 2018

Fixed by #176

Note that #176 will not pass tests until release v0.15.2 is included into libp2p2, and we include that version of libp2p2 in peer-star-app

@pgte
Copy link
Contributor

pgte commented Dec 19, 2018

@dirkmc this was fixed by #200, right?

@dirkmc
Copy link
Collaborator Author

dirkmc commented Dec 19, 2018

@pgte Yes, it was fixed - closing

@dirkmc dirkmc closed this as completed Dec 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants