Skip to content

Commit 356e148

Browse files
committed
fix: comment on preferred PodAntiAffinity
1 parent 73f54b6 commit 356e148

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

pkg/apis/core/types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3213,8 +3213,8 @@ type PodAntiAffinity struct {
32133213
// most preferred is the one with the greatest sum of weights, i.e.
32143214
// for each node that meets all of the scheduling requirements (resource
32153215
// request, requiredDuringScheduling anti-affinity expressions, etc.),
3216-
// compute a sum by iterating through the elements of this field and adding
3217-
// "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
3216+
// compute a sum by iterating through the elements of this field and subtracting
3217+
// "weight" from the sum if the node has pods which matches the corresponding podAffinityTerm; the
32183218
// node(s) with the highest sum are the most preferred.
32193219
// +optional
32203220
PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm

staging/src/k8s.io/api/core/v1/types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3597,8 +3597,8 @@ type PodAntiAffinity struct {
35973597
// most preferred is the one with the greatest sum of weights, i.e.
35983598
// for each node that meets all of the scheduling requirements (resource
35993599
// request, requiredDuringScheduling anti-affinity expressions, etc.),
3600-
// compute a sum by iterating through the elements of this field and adding
3601-
// "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
3600+
// compute a sum by iterating through the elements of this field and subtracting
3601+
// "weight" from the sum if the node has pods which matches the corresponding podAffinityTerm; the
36023602
// node(s) with the highest sum are the most preferred.
36033603
// +optional
36043604
// +listType=atomic

0 commit comments

Comments
 (0)