You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If Cleaner interface is implemented by a reconciler a finalizer is automatically added to the custom resource, and cleaner is called before it gets removed.
There is however a corner case when it makes sense to do cleanup event finalizer is not used. In case there is an in memory data held for a custom resource, so when a custom resource deleted, related indexed or in memory objects needs to be cleaned up. In this case a finalizer is not needed, since if the operator is down and the delete event is missed it's not a problem, since the cleanup is just for in memory data.
To support this we could add a feature flag to @ControllerConfiguration to don't add finalizer for cleanup: addFinalizerForCleaner.
Note that this is not a priority issue, we should probably implement it only if some requests it. Also having a finalizer in those cases would not be a big issues.
The text was updated successfully, but these errors were encountered:
@csviri hi~
I'm having a similar issue.
Sometimes, if Operator is removed before CR is completely deleted
Because of the finalizer set in CR, CR deletion is impossible
There is an inconvenience of having to forcibly remove the finalizer
Hi @10000-ki , I assume you are rather are talking about this problem: #1876
which will be solved eventually, this issue is about not having finalizers but still executing the cleanup code BUT JUST for the goal to cleanup some in-memory state. (Note that in case of operator restart that is cleaned up without finalizer by the OS). So this is not replacing the current behavior, just covering a corner use-case.
If
Cleaner
interface is implemented by a reconciler a finalizer is automatically added to the custom resource, and cleaner is called before it gets removed.There is however a corner case when it makes sense to do cleanup event finalizer is not used. In case there is an in memory data held for a custom resource, so when a custom resource deleted, related indexed or in memory objects needs to be cleaned up. In this case a
finalizer
is not needed, since if the operator is down and the delete event is missed it's not a problem, since the cleanup is just for in memory data.To support this we could add a feature flag to
@ControllerConfiguration
to don't add finalizer for cleanup:addFinalizerForCleaner
.Note that this is not a priority issue, we should probably implement it only if some requests it. Also having a finalizer in those cases would not be a big issues.
The text was updated successfully, but these errors were encountered: