New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dockershim: fix started and finished timestamp of the container status #99585
Conversation
Welcome @Iceber! |
Hi @Iceber. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/ok-to-test Add a release note like below. You may change the word.
|
I am going to modify the pull-kubernetes-bazel-test |
Signed-off-by: Iceber Gu <wei.cai-nat@daocloud.io>
/priority backlog |
LGTM |
var state runtimeapi.ContainerState | ||
var reason, message string | ||
ct, st, ft := createdAt.UnixNano(), int64(0), int64(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would the better fix be to change the defaults in getContainerTimestamps
? This way if docker returns bad times, kubernetes will report the same
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hm, never mind. I got it. I wonder what docker returns as a Finish time that is converted to -6795364578871345152
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
docker returns as a Finished time that is converted to 0
(0001-01-01T00:00:00Z
)
Please change the release note to:
|
/lgtm hold for changing the release note |
/hold cancel |
@SergeyKanzhelev the release note has been changed |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Iceber, mrunalp The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/test pull-kubernetes-e2e-kind |
Signed-off-by: Iceber Gu wei.cai-nat@daocloud.io
What type of PR is this?
/kind bug
What this PR does / why we need it:
When use
crictl
,Finished time is always1754-08-31T06:49:24.128654848+08:05
in the run and create states, becauseFinishedAt
is-6795364578871345152
I think the default started and finished timestamp should be 0(zero value), not
-6795364578871345152
.Which issue(s) this PR fixes:
Special notes for your reviewer:
fix
crictl
: kubernetes-sigs/cri-tools#724Convert
runtimeapi.ContainerStatus
tokubecontainer.Status
in thetoKubeContainerStatus
kubernetes/pkg/kubelet/kuberuntime/kuberuntime_container.go
Lines 510 to 522 in 793390e
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: