kubernetes-retired / kubefed

Kubernetes Cluster Federation
Apache License 2.0
2.5k stars 531 forks source link

clusterHealthCheckConfig FailureThreshold and SuccessThreshold not take effect #1496

Closed FengXingYuXin closed 2 years ago

FengXingYuXin commented 2 years ago

What happened: about below struct type ClusterHealthCheckConfig struct { Period time.Duration FailureThreshold int64 SuccessThreshold int64 Timeout time.Duration } we set Period 10s,FailureThreshold 100,SuccessThreshold 1,Timeout 60s。

but when kubefed check child k8s failed just only 1 time, the status of child k8s becomes notReady. What you expected to happen: the status of child k8s in kubefed becomes notReady after kubefed checks child k8s failed 10 times continuously.

How to reproduce it (as minimally and precisely as possible): version informations: 1)kubefed version: lastest 2) k8s version: maybe all versions, we use 1.11 3) kubefed contract child k8s use domain(kubefed->dns->lvs->nginx->child k8s apiserver)

just down(use reboot) one lvs node

Anything else we need to know?:

Environment:

/kind bug

FengXingYuXin commented 2 years ago

we check the code of clusterHealthCheck and find the bug in function thresholdAdjustedClusterStatus as followes: storedData.resultRun's updation must be in front of check image

k8s-triage-robot commented 2 years ago

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot commented 2 years ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot commented 2 years ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

k8s-ci-robot commented 2 years ago

@k8s-triage-robot: Closing this issue.

In response to [this](https://github.com/kubernetes-sigs/kubefed/issues/1496#issuecomment-1207205526): >The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. > >This bot triages issues and PRs according to the following rules: >- After 90d of inactivity, `lifecycle/stale` is applied >- After 30d of inactivity since `lifecycle/stale` was applied, `lifecycle/rotten` is applied >- After 30d of inactivity since `lifecycle/rotten` was applied, the issue is closed > >You can: >- Reopen this issue or PR with `/reopen` >- Mark this issue or PR as fresh with `/remove-lifecycle rotten` >- Offer to help out with [Issue Triage][1] > >Please send feedback to sig-contributor-experience at [kubernetes/community](https://github.com/kubernetes/community). > >/close > >[1]: https://www.kubernetes.dev/docs/guide/issue-triage/ Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.