mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-11 21:12:07 +00:00
Merge pull request #117516 from sourcelliu/intcast
Remove unnecessary type conversion
This commit is contained in:
commit
f997e50425
@ -267,7 +267,7 @@ func (n *nodeLogQuery) Copy(w io.Writer) {
|
||||
// set the deadline to the maximum across both runs
|
||||
ctx, cancel := context.WithDeadline(context.Background(), time.Now().Add(30*time.Second))
|
||||
defer cancel()
|
||||
boot := int(0)
|
||||
boot := 0
|
||||
if n.Boot != nil {
|
||||
boot = *n.Boot
|
||||
}
|
||||
|
@ -1658,7 +1658,7 @@ func killPodNow(podWorkers PodWorkers, recorder record.EventRecorder) eviction.K
|
||||
|
||||
// we timeout and return an error if we don't get a callback within a reasonable time.
|
||||
// the default timeout is relative to the grace period (we settle on 10s to wait for kubelet->runtime traffic to complete in sigkill)
|
||||
timeout := int64(gracePeriod + (gracePeriod / 2))
|
||||
timeout := gracePeriod + (gracePeriod / 2)
|
||||
minTimeout := int64(10)
|
||||
if timeout < minTimeout {
|
||||
timeout = minTimeout
|
||||
|
@ -500,7 +500,7 @@ func TestStatusNormalizationEnforcesMaxBytes(t *testing.T) {
|
||||
Name: fmt.Sprintf("container%d", i),
|
||||
LastTerminationState: v1.ContainerState{
|
||||
Terminated: &v1.ContainerStateTerminated{
|
||||
Message: strings.Repeat("abcdefgh", int(24+i%3)),
|
||||
Message: strings.Repeat("abcdefgh", 24+i%3),
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
systemPriority = int32(scheduling.SystemCriticalPriority)
|
||||
systemPriority = scheduling.SystemCriticalPriority
|
||||
systemPriorityUpper = systemPriority + 1000
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user