Skip to content

Conversation

@dmitry-markin
Copy link
Collaborator

Add reuse_port option to TCP & WebSocket configs. When set, this both:

  1. Sets SO_REUSEPORT on sockets.
  2. Binds sockets to the listen address port when making outbound connections.

I'm not sure if these two behaviors should be controlled by a single option, but this follows libp2p convention.

CC @altonen

@dmitry-markin dmitry-markin added the enhancement New feature or request label Mar 29, 2024
@dmitry-markin dmitry-markin requested a review from lexnv March 29, 2024 15:25
@dmitry-markin dmitry-markin self-assigned this Mar 29, 2024
@dmitry-markin
Copy link
Collaborator Author

While at this PR I noticed that our rustfmt.toml doesn't include match_block_trailing_comma = true, which is present in poladot-sdk rustfmt.toml. I'm going to add it and reformat the repo in a follow-up PR if you don't mind @altonen @lexnv

@dmitry-markin dmitry-markin merged commit e0f5b65 into master Apr 1, 2024
@dmitry-markin dmitry-markin deleted the dm-port-reuse-toggle branch April 1, 2024 09:12
@lexnv lexnv mentioned this pull request Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

Status: Blocked ⛔️

Development

Successfully merging this pull request may close these issues.

4 participants