Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR implements a mini-server-pool that we talked about in #4 as the second option.
We also created four such servers on free Heroku accounts, to be able to open a test site. We expose the server names for you to work on the client with multiple servers (via npm run start:remote which uses localhost for client and remote server pool for chess STT inference). As these servers are on free accounts, they most probably be in sleep mode, so it will take a couple of seconds until they wake up, so put a 3x connection trial and a timeout of 5 sec.
It basically starts with the first server and tries to connect. If the server is full, it loops through the server pool until an empty one is found. Each server continues to host a single session.