You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
fix: Windows support for bundled gateway startup (#59)
* fix: use platform classpath separator when launching gateway
The Java classpath joined the config dir, jar, and runtime glob with a
hardcoded ":", which is only valid on macOS/Linux. On Windows the classpath
separator is ";" and ":" also appears in drive letters (C:\...), so the JVM
got one mangled entry, found none of the classes, and exited with:
Could not find or load main class ibgroup.web.core.clientportal.gw.GatewayStart
Caused by: java.lang.ClassNotFoundException
Join with path.delimiter so the classpath is correct on every platform.
* fix: detect port availability by binding instead of parsing netstat
isPortAvailable shelled out to `netstat -an | findstr :PORT` on Windows,
which matches substrings: checking port 5000 also matched ephemeral ports
such as 50001, 50003, etc. One is almost always present, so the default
port was reported busy and the gateway started on 5001 while the REST
client kept talking to 5000 - the browser session authenticated but the
client never saw it.
Replace the netstat/lsof/ss parsing with a direct bind attempt using the
net module: accurate, no substring pitfall, and no shell spawned per check.