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

fix(rust): don't use failed identify messages to detect disconnection #93

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

thomaseizinger
Copy link
Contributor

@thomaseizinger thomaseizinger commented Sep 24, 2023

Previously, we were using a timeout on the identify protocol to detect disconnected peers. Detecting closed browser tabs within the transport stack now works correctly so we no longer need this hack.

I tested this locally using the latest deployed version on vercel.app.

@vercel
Copy link

vercel bot commented Sep 24, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
universal-connectivity ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 4, 2023 2:06am

@thomaseizinger

This comment was marked as outdated.

@thomaseizinger thomaseizinger changed the title refactor(rust): use ping for detecting disconnected peers fix(rust): don't use failed identify messages to detect disconnection Oct 4, 2023
@thomaseizinger
Copy link
Contributor Author

While working on this, I noticed a strange behaviour @libp2p/js-libp2p-dev. The js-peer within this repository doesn't support the ping protocol. That is fine. What is weird is that I am running into negotiation timeouts when trying to use it. In other words, multistream-select doesn't seem to correctly respond with na. Instead, it seems to just not return anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant