Description
In Dependent Resources Deleter
means that the resources needs to be explicitly deleted during a cleanup. However also implies that the resource is coupled to the custom resource in a sense that during the reconciliation this resource might be deleted. See:
For managed dependent resources this is handled automatically by the system, also means that finalizer will be utilized for the custom resource.
For managed dependent resources there is an issue with this in terms of deleting, regarding the resources which are garbage collected rather then explicitly deleted. Note that in scope of v3.0.0 the deletion during a reconciliation was out of the scope for managed resources. But with workflows this will be introduced, see: #850 (If Condition
not holds, the resource should be deleted during the reconciliation)
Issue / Goal
The issue is that for Kubernetes dependent resources where owner references can be used, we want to have the resource Deleter
if it might be deleted also during the reconciliation, but we don't want to use finalizers
because of this, and we don't want to explicitly delete the dependent during cleanup
phase, rather the k8s garbage collection needs to clean it up.
Proposed Solution
A way we could handle this globally is to introduce a GarbageCollected
empty marker interface, that when implemented in combination with Deleter
, would have the desired effect as describe above. Thus the resource might be deleted explicitly during the reconciliation, but won't be at cleanup
, and finalizer
won't be added because of this resources.