Ecdar / Ecdar/j-Ecdar

Dynamically find Grpc port

Open
#84 0 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue
Dominant language
Java
Stars
4
Forks
9
PR merge metrics
No merged PRs in 30d

Description

[GrpcServer](https://github.com/Ecdar/j-Ecdar/pull/74/files#diff-80f85b381a9d4f4cb994cc29fa1071cf0bc4c510275ac789c1b2201607e03ee6) per #74 now uses port *9000*. However, I believe we should prioritize this port, or another one, but if it is already in use then we should select another one dynamically. For inspiration [this](https://stackoverflow.com/questions/2231467/dynamically-choosing-port-number) and [this](https://stackoverflow.com/questions/2675362/how-to-find-an-available-port), the important aspects is the general approach for finding the available port by using port *0*. We also need to consider configuration for automatic deployment in an unknown environment. Given that j-Ecdar is designed as a server, we cannot always listen to a random port as the server may be configured in such a way that it relies on j-Ecdar stopping if the port is unavailable. Because of this we must also provide a way to configure j-Ecdar not to choose a random available port.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the GrpcServer introduced in pull request #74 and inspect how port 9000 is currently selected. Define and implement the configuration behavior for choosing an available port via port 0 while retaining an option to fail when the configured port is unavailable; verify both modes in the server setup.

Written by the indexing model from the issue text.

Assessment

Tech stack
grpc, java
Domain
backend, networking
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.