-
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
Unexpected workspace restart due to scale down of a replicaset #22750
Comments
@amisevsk do you happen to have any ideas why deployment could be scaled down randomly? |
Adding devworkspace-operator label for initial investigation, however, it might completely unrelated to DWO |
I'm not sure the steps to reproduce is complete -- when I start a workspace from the provided devfile, the dashboard is not cloned and I don't see any commands (maybe a bug in the che-tasks-extension?). I cloned the che-dashboard repository and opened it in code but the devfile tasks failed to run at that point. |
Hi @amisevsk , That's my fault, I missed some steps in the How to reproduce section. I've added missed steps, and hopefully, now it should work. |
Hi @akurinnoy -- looks like your edits didn't get saved. The steps look the same as before to me :) |
@amisevsk Finally I've updated the description, sorry for that :) |
Thanks! I was able to reproduce the issue now (after running From the DWO logs, it is indeed updating the workspace deployment which is triggering a rollout (i.e. a new pod since the replicaset is updated). This seems to be due to something updating the DevWorkspace to have a new environment variable:
which is coming from the che-code editor's DevWorkspaceTemplate. @akurinnoy Is there a chance the dashboard, while running in dogfooding mode, is updating this DevWorkspaceTemplate to use its current dashboard URL? |
@amisevsk let me check it. |
Hi @amisevsk , |
I'll take another look. |
I've tested it again on dogfooding and what I've found is that as soon as I load the dashboard in my browser, the URL for Since DWO does not automatically trigger reconciles when DevWorkspaceTemplates are updated, this change is not initially noticed by the DevWorkspace Operator. However, when something does trigger a reconcile on the workspace, DWO will notice that the resolve workspace has a different oc annotate --overwrite dw $DEVWORKSPACE_NAME -n $DEVWORKSPACE_NAMESPACE "recon
cile=$(date +%s)" (Run this in the workspace terminal) To track changes to the CHE_DASHBOARD_URL env var, I used the following bash snippet: while true; do
date
oc get dwt che-code-che-dashboard -o yaml | grep -A 1 CHE_DASHBOARD_URL
sleep 1
done while this is running, reload either the usual Che dashboard or the one running within your workspace to see the effect. I'm still not sure where the env var is getting set, but it seems to be on first load of the dashboard page. |
Describe the bug
Using Che on the dogfooding cluster, I noticed my workspace being restarted. It seems to happen when I pause typing in the editor for a few minutes.
Che version
7.79@latest
Steps to reproduce
(updated)
Expected behavior
The workspace does not restart on its own.
Runtime
OpenShift
Screenshots
Installation method
other (please specify in additional context)
Environment
other (please specify in additional context)
Eclipse Che Logs
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: