Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@AvhiMaz
Copy link

@AvhiMaz AvhiMaz commented Nov 12, 2025

Problem

SocketAddrSpace struct is not streamer-specific but resides in solana-streamer crate, forcing unnecessary dependencies on the entire streamer crate for code that only needs address space validation.

Summary of Changes

  • Move SocketAddrSpace enum and implementation from solana-streamer to solana-net-utils
  • Update all req files to import from the new location (solana_net_utils::socket_addr_space::SocketAddrSpace)
  • Add deprecation warning to streamer's re-export for backward compatibility (since = "4.0.0")
  • Remove socket module from streamer's public API (lib.rs)
  • Add solana-net-utils dependency to affected test packages (cli, tokens)

Fixes #9027

  Move SocketAddrSpace from solana-streamer to solana-net-utils where it
  logically belongs. This reduces unnecessary dependencies on the streamer
  crate for code that only needs address space validation.

  Changes:
  - Move SocketAddrSpace enum and implementation to net-utils
  - Update all req files to import from new location
  - Add deprecation warning to streamer re-export for backward compatibility
  - Remove socket module from streamer's public API

  Fixes anza-xyz#9027

Signed-off-by: AvhiMaz <[email protected]>
@mergify
Copy link

mergify bot commented Nov 12, 2025

If this PR represents a change to the public RPC API:

  1. Make sure it includes a complementary update to rpc-client/ (example)
  2. Open a follow-up PR to update the JavaScript client @solana/kit (example)

Thank you for keeping the RPC clients in sync with the server API @AvhiMaz.

@alexpyattaev
Copy link

Unfortunately, the issue was already claimed by a different contributor before you have indicated interest. To deconflict the development efforts, you could take a look at e.g. #9032 (but please post on the issue that you are working on a fix before committing actual dev effort).

@AvhiMaz AvhiMaz closed this Nov 12, 2025
@AvhiMaz AvhiMaz deleted the refactor/move-socket-addr-space-to-net-utils branch November 12, 2025 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor SocketAddrSpace into net-utils

2 participants