-
Notifications
You must be signed in to change notification settings - Fork 55
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
Cherry pick for 0.15.1 #885
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Make sure we merge both the dwoc proxy config and the cluster proxy config on OpenShift to avoid an issue where we ignore the cluster proxy if the dwoc contains a proxy config on start. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit 033fa05)
Signed-off-by: Andrew Obuchowicz <[email protected]> (cherry picked from commit 540f408)
Fix devfile#551 Signed-off-by: Andrew Obuchowicz <[email protected]> (cherry picked from commit f3e317a)
Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit 480d686)
Rework how we update workspace status to avoid multiple calls that update the workspace status. Previously, every time we enter the finalize function, we would set the status to terminating, and then potentially set it to errored. Instead, we use the same deferred-function handling of updating the workspace status from main reconcile function -- defer a function that updates the status and pass around a currentStatus struct reference that needs to be updated. This moves all calls that update the workspace status into one place. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit eaa8381)
With the update to terminating workspace status handling (see previous commit), it turns out it's no longer necessary to stop reconciling workspaces once their job encounters an error. The previous bug where DWO would enter a tight loop reconciling failed workspaces turns out to be due to each finalize call updating the workspace to Terminating status, then to Errored status, triggering a new reconcile. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit 8865f7f)
When the last finalizer on a DevWorkspace is cleared, the cluster may garbage-collect that workspace immediately, which can result in the object being deleted before we reach the point of attempting to update the workspace's status. This results in logging a harmless but confusing error, so we don't try to update the status for terminating workspaces with no finalizers. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit e3805fb)
Since setting a workspace to the errored status will queue another reconcile, we only log the "failed to clean up common PVC" message if the workspace status is not already set to errored. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit 225fbf1)
To make sure workspaces that are in an errored state due to PVC cleanup failing are removed when the common PVC is deleted (e.g. when all DevWorkspaces are deleted), add a watch and enqueue reconciles for all common-storage workspaces when the common PVC is deleted. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit a2e149f)
Update the watch for PVCs to also enqueue reconciles for per-workspace PVC events. Previously, the per-workspace PVC could be modified/deleted without the DevWorkspace that owns that PVC noticing. Signed-off-by: Angel Misevski <[email protected]> (cherry picked from commit 2a44ff6)
Update ubi-minimal base image to tag '8.6-854' and ubi8/go-toolset to tag '1.17.10-4' Signed-off-by: Angel Misevski <[email protected]>
ibuziuk
approved these changes
Jul 5, 2022
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: amisevsk, ibuziuk The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What does this PR do?
Cherry-pick fixes from main branch into 0.15.x:
What issues does this PR fix or reference?
See above
Is it tested? How?
PR Checklist
/test v8-devworkspace-operator-e2e, v8-che-happy-path
to trigger)v8-devworkspace-operator-e2e
: DevWorkspace e2e testv8-che-happy-path
: Happy path for verification integration with Che