Skip to content

Commit 7df1259

Browse files
committed
Generated changes for probe terminationGracePeriodSeconds
1 parent 06e634e commit 7df1259

File tree

74 files changed

+17716
-17164
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+17716
-17164
lines changed

api/openapi-spec/swagger.json

+6-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/api/pod/util.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -836,7 +836,7 @@ func probeGracePeriodInUse(podSpec *api.PodSpec) bool {
836836
VisitContainers(podSpec, AllContainers, func(c *api.Container, containerType ContainerType) bool {
837837
// cannot be set for readiness probes
838838
if (c.LivenessProbe != nil && c.LivenessProbe.TerminationGracePeriodSeconds != nil) ||
839-
(c.StartupProbe != nil && c.StartupProbe.TerminationGracePeriodSeconds != nil) {
839+
(c.StartupProbe != nil && c.StartupProbe.TerminationGracePeriodSeconds != nil) {
840840
inUse = true
841841
return false
842842
}

pkg/api/pod/util_test.go

+7-7
Original file line numberDiff line numberDiff line change
@@ -1146,8 +1146,8 @@ func TestDropProbeGracePeriod(t *testing.T) {
11461146
podWithProbeGracePeriod := func() *api.Pod {
11471147
return &api.Pod{
11481148
Spec: api.PodSpec{
1149-
RestartPolicy: api.RestartPolicyNever,
1150-
Containers: []api.Container{{Name: "container1", Image: "testimage", LivenessProbe: &probe, StartupProbe: &probe}},
1149+
RestartPolicy: api.RestartPolicyNever,
1150+
Containers: []api.Container{{Name: "container1", Image: "testimage", LivenessProbe: &probe, StartupProbe: &probe}},
11511151
},
11521152
}
11531153
}
@@ -1176,11 +1176,11 @@ func TestDropProbeGracePeriod(t *testing.T) {
11761176
{
11771177
description: "only has liveness probe-level terminationGracePeriod",
11781178
hasGracePeriod: true,
1179-
pod: func() *api.Pod {
1180-
p := podWithProbeGracePeriod()
1181-
p.Spec.Containers[0].StartupProbe.TerminationGracePeriodSeconds = nil
1182-
return p
1183-
},
1179+
pod: func() *api.Pod {
1180+
p := podWithProbeGracePeriod()
1181+
p.Spec.Containers[0].StartupProbe.TerminationGracePeriodSeconds = nil
1182+
return p
1183+
},
11841184
},
11851185
{
11861186
description: "is nil",

pkg/apis/core/v1/zz_generated.conversion.go

+2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/apis/core/zz_generated.deepcopy.go

+5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)