mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-12-04 07:05:37 +00:00
We recently changed `SyncPods` to filter out terminated pods at the beginning for two reasons: * performance: kubelet no longer keeps goroutines to checks containers for terminated pods. * correctness: kubelet relies on inspecting dead containers to generate pod status. Because dead containers may get garbage collected and kubelet does not have checkpoints yet, syncing terminated pod could lead to modifying the status of a terminated pod. However, even though kubelet should not *sync* the terminated pods, it should not attempt to remove the directories and volumes for such pods as long as they have not been deleted. This change fixes aggresive directory removal by passing all pods (including terminated pods) to the cleanup functions.
136 KiB
136 KiB