-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
It is not possible to run more than one Che 7 workspace at a time #12238
Comments
It is caused by the issue: service discovery of APIs running in tooling containers of Workspace.Next #9913 |
@sleshchenko I have added some notes about a possible solution. That's something we discussed with @benoitf last week. cc @evidolob |
Linking original PR made by @garagatyi #10528 |
@l0rd is this issue a priority for the next sprint ? |
@ibuziuk no |
I wonder why you think that they use localhost?
Do you mean prefixing only services created by plugins or also those that are in the user recipe of a workspace?
For the start we might be OK with just having an env var with workspace ID and knowing that we need to prefix service name with it prefix. |
Because if you started an HTTP service on port 80 of container A, you can reach it as
That's a good question. But no we should not prefix services defined in the user runtime. It will be the user responsibility not make them collide with other services and that it's perfectly fine because he should complete control of the services running in the namespace.
That's a hack that plugin developer should apply in their plugins and we don't want because their plugins may be broken as soon as we fix it in the right way. We want to go with the clean solution right away. |
@l0rd actually our plugins don't use localhost. They use k8s Service. And this is a PITA. I have a POC for this but it leads to:
This solution makes us split the knowledge about prefixing k8s services with workspace ID among different components with different lifecycles. You mentioned that we want to go with a clean solution and I believe that this solution is not clean solution at all.
We do not show internal plugin endpoints in Che workspace API at the moment. Hello world plugin doesn't work as it was expected. |
Here is another way to implement this: I'm going to provide PR with this solution. If somebody has any thought why should we go to another direction, please, comment. |
@l0rd @sleshchenko FYI |
Just discussed this idea with @sleshchenko and he pointed out that Theia editor server name would be changed. Which is not OK. So, can't proceed with this solution |
One problem with the solution suggested in the issue description is that since service discovery would be dependent on the workspace ID we can't just cache brokering results without modifying on each request with a certain workspace ID. |
A quick win could be:
And here is a wider explanation of options we have and what are the pros and cons: What we do now:
What options we have to allow running several workspaces in a single k8s namespace:
Pros:
Pros:
Pros:
I would go with option 3 and here is how to do it in an iterable way:
DONE! |
I recalled that we had Fortune and Hello world plugins that are using sidecars and rely on predictable sidecar URLs. They need to be adapted to fetch endpoint URL from Che master API. |
It seems that plugins like these can make UX worse, but since we do not expect heavy usage of plugins other than Theia and VS Code type this should not be a problem for the time being. |
Description
If a Che 7 workspace is running and I try to start a new one I get the following error:
One possible solution to address this problem would be to suffix the name of services with the workspace id:
The text was updated successfully, but these errors were encountered: