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

FEATURE: Auto select server port #479

Merged
merged 2 commits into from
Jan 16, 2025
Merged

FEATURE: Auto select server port #479

merged 2 commits into from
Jan 16, 2025

Conversation

isaacwaldron
Copy link
Collaborator

Add a function _find_available_port to find a port in the range [50051, 60000] that is available to open a listening socket on. Use this function to automatically select a port when either launch_session or session are used to launch a gRPC server session
and port_num is None (the default).

Closes #478

Add a test that demonstrates the failure when the default port 50051 is
already in use.
Add a function `_find_available_port` to find a port in the range
[50051, 60000] that is available to open a listening socket on.  Use
this function to automatically select a port when either
`launch_session` or `session` are used to launch a gRPC server session
and `port_num` is `None` (the default).
@drewm102 drewm102 merged commit 915e297 into main Jan 16, 2025
25 checks passed
@drewm102 drewm102 deleted the auto-select-port branch January 16, 2025 20:12
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.

Automatically select available port for session and launch_session
3 participants