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

feat(networking): integrate autonat service to request if we are dialable #1472

Merged
merged 1 commit into from
Jan 11, 2023

Conversation

alrevuelta
Copy link
Contributor

@alrevuelta alrevuelta commented Dec 21, 2022

Closes #1206

Summary:
This PR integrates the brand new AutonatService added in nim-libp2p. This service runs in the background asking other outbound connected peers to dial us, informing us if we are Reachable or NotReachable by them.

  • Reachability state is logged every 2 minutes: Reachable/NotReachable.
  • nim-libp2p metric can be reused. See:
libp2p_autonat_reachability_confidence{reachability="Reachable"} 1.0
libp2p_autonat_reachability_confidence{reachability="NotReachable"} 0.0

Done:

  • Integrate autonatservice.
  • Test Reachable state (opening ports)
  • Test NotReeachable state (closing ports)

Note that this is an experimental feature that was never tested in nim-libp2p in a production environment, but it only impact logs and one metric, so its impact is really low.

@status-im-auto
Copy link
Collaborator

status-im-auto commented Dec 21, 2022

Jenkins Builds

Click to see older builds (2)
Commit #️⃣ Finished (UTC) Duration Platform Result
21c12b0 #1 2022-12-21 23:06:05 ~18 min macos 📄log
027629e #2 2022-12-22 23:00:58 ~13 min macos 📄log
Commit #️⃣ Finished (UTC) Duration Platform Result
c9150ad #3 2022-12-23 22:59:39 ~12 min macos 📄log
33de5e6 #4 2023-01-03 22:52:05 ~4 min macos 📄log

@alrevuelta alrevuelta changed the title Integrate autonat service to request if we are dialable feat(networking): integrate autonat service to request if we are dialable Jan 3, 2023
@alrevuelta alrevuelta force-pushed the integrate-autonat branch 5 times, most recently from 7ca6309 to 810b08e Compare January 10, 2023 10:53
@alrevuelta
Copy link
Contributor Author

@jm-clius To be rebased on top of #1480 once merged. So disregard the nim-libp2p version bump.

@alrevuelta alrevuelta marked this pull request as ready for review January 10, 2023 11:09
@alrevuelta alrevuelta requested review from jm-clius and LNSD January 10, 2023 11:09
Copy link
Contributor

@LNSD LNSD left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✅

Copy link
Contributor

@jm-clius jm-clius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Nice feature.

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.

feat(networking): new metric showing if node is reachable
4 participants