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

core: randomize p2p ports; consolidate GetFreePort implementations #10884

Merged
merged 1 commit into from
Oct 9, 2023

Conversation

jmank88
Copy link
Contributor

@jmank88 jmank88 commented Oct 7, 2023

This should reduce occurrences of bind: address already in use like:

failed to start ragep2p host: net.Listen("127.0.0.1:20005") failed: listen tcp 127.0.0.1:20005: bind: address already in use

@jmank88 jmank88 requested review from a team and samsondav as code owners October 7, 2023 15:06
@jmank88 jmank88 requested a review from a team October 7, 2023 15:06
@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

I see that you haven't updated any CHANGELOG files. Would it make sense to do so?

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

I see that you haven't updated any README files. Would it make sense to do so?

@cl-sonarqube-production
Copy link

SonarQube Quality Gate

Quality Gate failed

Failed condition 8.3% 8.33% Duplicated Lines (%) on New Code (is greater than 3%)

See analysis details on SonarQube

@jmank88 jmank88 enabled auto-merge October 7, 2023 15:46
// GetFreePort returns a free port.
// NOTE: This approach is technically incorrect because the returned port
// can still be taken by the time the caller attempts to bind to it.
// Unfortunately, we can't specify zero port in P2P.V2.ListenAddresses at the moment.
Copy link
Contributor

Choose a reason for hiding this comment

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

@jmank88 jmank88 added this pull request to the merge queue Oct 9, 2023
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Oct 9, 2023
@jmank88 jmank88 added this pull request to the merge queue Oct 9, 2023
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Oct 9, 2023
@makramkd makramkd added this pull request to the merge queue Oct 9, 2023
Merged via the queue into develop with commit 7dbb38b Oct 9, 2023
@makramkd makramkd deleted the randomize-ports branch October 9, 2023 10:10
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.

3 participants