Skip to content

Commit ef439d6

Browse files
committed
KEP-1287: Fix PodResizeInProgress condition references
1 parent 913c8ab commit ef439d6

File tree

1 file changed

+12
-12
lines changed
  • keps/sig-node/1287-in-place-update-pod-resources

1 file changed

+12
-12
lines changed

keps/sig-node/1287-in-place-update-pod-resources/README.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ The `ResizePolicy` field is immutable.
298298

299299
#### Resize Status
300300

301-
Resize status will be tracked via 2 new pod conditions: `PodResizePending` and `PodResizing`.
301+
Resize status will be tracked via 2 new pod conditions: `PodResizePending` and `PodResizeInProgress`.
302302

303303
**PodResizePending** will track states where the spec has been resized, but the Kubelet has not yet
304304
allocated the resources. There are two reasons associated with this condition:
@@ -313,7 +313,7 @@ admitted. `lastTransitionTime` will be populated with the time the condition was
313313
will always be `True` when the condition is present - if there is no longer a pending resized
314314
(either the resize was allocated or reverted), the condition will be removed.
315315

316-
**PodResizing** will track in-progress resizes, and should be present whenever allocated resources
316+
**PodResizeInProgress** will track in-progress resizes, and should be present whenever allocated resources
317317
!= acknowledged resources (see [Resource States](#resource-states)). For successful synchronous
318318
resizes, this condition should be short lived, and `reason` and `message` will be left blank. If an
319319
error occurs while actuating the resize, the `reason` will be set to `Error`, and `message` will be
@@ -556,23 +556,23 @@ This is intentionally hitting various edge-cases for demonstration.
556556
- `status.containerStatuses[0].allocatedResources[cpu]` = 1.5
557557
- `acknowledged[cpu]` = 1
558558
- `status.containerStatuses[0].resources.requests[cpu]` = 1
559-
- `status.conditions[type==PodResizing]` added
559+
- `status.conditions[type==PodResizeInProgress]` added
560560
- actual CPU shares = 1024
561561

562562
1. Resize #2: cpu = 2
563563
- apiserver validates the request and accepts the operation
564564
- `spec.containers[0].resources.requests[cpu]` = 2
565565
- `status.containerStatuses[0].allocatedResources[cpu]` = 1.5
566566
- `status.containerStatuses[0].resources.requests[cpu]` = 1
567-
- `status.conditions[type==PodResizing]`
567+
- `status.conditions[type==PodResizeInProgress]`
568568
- actual CPU shares = 1024
569569

570570
1. Container runtime applied cpu=1.5
571571
- `spec.containers[0].resources.requests[cpu]` = 2
572572
- `status.containerStatuses[0].allocatedResources[cpu]` = 1.5
573573
- `acknowledged[cpu]` = 1.5
574574
- `status.containerStatuses[0].resources.requests[cpu]` = 1
575-
- `status.conditions[type==PodResizing]`
575+
- `status.conditions[type==PodResizeInProgress]`
576576
- actual CPU shares = 1536
577577

578578
1. kubelet syncs the pod, and sees resize #2 (cpu = 2)
@@ -582,7 +582,7 @@ This is intentionally hitting various edge-cases for demonstration.
582582
- `acknowledged[cpu]` = 1.5
583583
- `status.containerStatuses[0].resources.requests[cpu]` = 1.5
584584
- `status.conditions[type==PodResizePending].type` = `"Deferred"`
585-
- `status.conditions[type==PodResizing]` removed
585+
- `status.conditions[type==PodResizeInProgress]` removed
586586
- actual CPU shares = 1536
587587

588588
1. Resize #3: cpu = 1.6
@@ -600,23 +600,23 @@ This is intentionally hitting various edge-cases for demonstration.
600600
- `acknowledged[cpu]` = 1.5
601601
- `status.containerStatuses[0].resources.requests[cpu]` = 1.5
602602
- `status.conditions[type==PodResizePending]` removed
603-
- `status.conditions[type==PodResizing]` added
603+
- `status.conditions[type==PodResizeInProgress]` added
604604
- actual CPU shares = 1536
605605

606606
1. Container runtime applied cpu=1.6
607607
- `spec.containers[0].resources.requests[cpu]` = 1.6
608608
- `status.containerStatuses[0].allocatedResources[cpu]` = 1.6
609609
- `acknowledged[cpu]` = 1.6
610610
- `status.containerStatuses[0].resources.requests[cpu]` = 1.5
611-
- `status.conditions[type==PodResizing]`
611+
- `status.conditions[type==PodResizeInProgress]`
612612
- actual CPU shares = 1638
613613

614614
1. Kubelet syncs the pod
615615
- `spec.containers[0].resources.requests[cpu]` = 1.6
616616
- `status.containerStatuses[0].allocatedResources[cpu]` = 1.6
617617
- `acknowledged[cpu]` = 1.6
618618
- `status.containerStatuses[0].resources.requests[cpu]` = 1.6
619-
- `status.conditions[type==PodResizing]` removed
619+
- `status.conditions[type==PodResizeInProgress]` removed
620620
- actual CPU shares = 1638
621621

622622
1. Resize #4: cpu = 100
@@ -738,18 +738,18 @@ Impacts of a restart outside of resource configuration are out of scope.
738738
1. Updated pod is synced: Check if pod can be admitted
739739
- No: add `PodResizePending` condition with type `Deferred`, no change to allocated resources
740740
- Restart: redo admission check, still deferred.
741-
- Yes: add `PodResizing` condition, update allocated checkpoint
741+
- Yes: add `PodResizeInProgress` condition, update allocated checkpoint
742742
- Restart before update: readmit, then update allocated
743743
- Restart after update: allocated != acknowledged --> proceed with resize
744744
1. Allocated != Acknowledged
745745
- Trigger an `UpdateContainerResources` CRI call, then update Acknowledged resources on success
746746
- Restart before CRI call: allocated != acknowledged, will still trigger the update call
747747
- Restart after CRI call, before acknowledged update: will redo update call
748748
- Restart after acknowledged update: allocated == acknowledged, condition removed
749-
- In all restart cases, `LastTransitionTime` is propagated from the old pod status `PodResizing`
749+
- In all restart cases, `LastTransitionTime` is propagated from the old pod status `PodResizeInProgress`
750750
condition, and remains unchanged.
751751
1. PLEG updates PodStatus cache, triggers pod sync
752-
- Pod status updated with actual resources, `PodResizing` condition removed
752+
- Pod status updated with actual resources, `PodResizeInProgress` condition removed
753753
- Desired == Allocated == Acknowledged, no resize changes needed.
754754

755755
#### Notes

0 commit comments

Comments
 (0)