Merge pull request #132102 from tallclair/allocation-failure

Only set pod allocation if admission succeeds
This commit is contained in:
Kubernetes Prow Robot
2025-06-04 14:46:45 -07:00
committed by GitHub

View File

@@ -243,7 +243,7 @@ func (m *manager) AddPod(activePods []*v1.Pod, pod *v1.Pod) (bool, string, strin
allocatedPods := m.getAllocatedPods(activePods)
ok, reason, message := m.canAdmitPod(allocatedPods, pod)
if utilfeature.DefaultFeatureGate.Enabled(features.InPlacePodVerticalScaling) {
if ok && utilfeature.DefaultFeatureGate.Enabled(features.InPlacePodVerticalScaling) {
// Checkpoint the resource values at which the Pod has been admitted or resized.
if err := m.SetAllocatedResources(pod); err != nil {
// TODO(vinaykul,InPlacePodVerticalScaling): Can we recover from this in some way? Investigate