-
Notifications
You must be signed in to change notification settings - Fork 994
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
Avoid orphaned objects on delete #654
Conversation
#218 is a totally different issue caused by an early return when an error happens during deletion |
cl.Name = clusterName.Name
cl.Namespace = clusterName.Namespace in addCluster ? Looks like line 179 reads inconsistent state of |
After some experiments I think the synchronization of The following sequence of events leads to that situation:
The practical consequence of the bug is that certain resources - for example pods - stay around forever, preventing rolling updates or creation of a cluster with the same name. Deletions during @FxKu the solution I found is to add |
Thanks @sdudoladov for finding the source of this problem. Changed the code accordingly. Btw. the problem also occurred when the cluster failed to get into a running state (e.g. by specifying non-existing Docker image) and a user then tries to delete the cluster. So, you're probably right with the |
👍 |
1 similar comment
👍 |
If a cluster is deleted immediately after creation, fields of the
cluster
struct are empty when processing the DELETE event. The same might happen when a cluster doesn't get into theRunning
state at all.fixes #551