mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-15 06:43:54 +00:00
optimize the comment
Signed-off-by: Ziqi Zhao <zhaoziqi9146@gmail.com>
This commit is contained in:
parent
51495bb4c5
commit
e92501b8fc
@ -1956,10 +1956,11 @@ func (kl *Kubelet) SyncPod(ctx context.Context, updateType kubetypes.SyncPodType
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(#113606): connect this with the incoming context parameter, which comes from the pod worker.
|
// TODO(#113606): use cancellation from the incoming context parameter, which comes from the pod worker.
|
||||||
// Currently, using that context causes test failures. To remove this todoCtx, any wait.Interrupted
|
// Currently, using cancellation from that context causes test failures. To remove this WithoutCancel,
|
||||||
// errors need to be filtered from result and bypass the reasonCache - cancelling the context for
|
// any wait.Interrupted errors need to be filtered from result and bypass the reasonCache - cancelling
|
||||||
// SyncPod is a known and deliberate error, not a generic error.
|
// the context for SyncPod is a known and deliberate error, not a generic error.
|
||||||
|
// Use WithoutCancel instead of a new context.TODO() to propagate trace context
|
||||||
// Call the container runtime's SyncPod callback
|
// Call the container runtime's SyncPod callback
|
||||||
sctx := context.WithoutCancel(ctx)
|
sctx := context.WithoutCancel(ctx)
|
||||||
result := kl.containerRuntime.SyncPod(sctx, pod, podStatus, pullSecrets, kl.backOff)
|
result := kl.containerRuntime.SyncPod(sctx, pod, podStatus, pullSecrets, kl.backOff)
|
||||||
|
Loading…
Reference in New Issue
Block a user