Garbage Collection Flashcards
How are owners and dependents references used?
Owners and dependents references are used for garbage collection. In order to ensure resources that are marked for deletion belong to the proper owner, dependent resources are marked with the owner reference. For example: A service creates EndpointSlice resources marked with a reference to the owner service.
What types of resource deletion are there, which is the default?
2 Forward cascading and background cascading deletion. On the first the dependents are deleted first and the owner deleted after dependents with blockOwnerDeletion set to true are deleted (by default blockOwnerDeletion is set to true). Background cascading deletion the owner is deleted first and the controller cleans up the dependent resources in the background. This last method is the default.