should update pediacluster status when conditions or SyncResources changed rather than timed execution #341
duanmengkk
started this conversation in
Ideas
Replies: 2 comments 4 replies
-
What is the version of clusterpedia? Although it is checked once every 5 seconds, the status update log is not printed if the status has not changed. Can you give me a more complete log, the picture has cut off part of the log. |
Beta Was this translation helpful? Give feedback.
2 replies
-
I'm running clustersynchro manager with the main branch I0905 18:01:22.612425 8227 clustersynchro_manager.go:498] "Update Cluster Status" cluster="cluster-example" conditions=[{Type:Validated Status:True ObservedGeneration:0 LastTransitionTime:2022-08-02 12:46:34 +0800 CST Reason:Validated Message:} {Type:SynchroRunning Status:True ObservedGeneration:0 LastTransitionTime:2022-09-05 18:01:14 +0800 CST Reason:Running Message:cluster synchro is running} {Type:ClusterHealthy Status:True ObservedGeneration:0 LastTransitionTime:2022-09-05 18:01:15 +0800 CST Reason:Healthy Message:cluster health responded with ok} {Type:Ready Status:True ObservedGeneration:0 LastTransitionTime:2022-09-05 18:01:15 +0800 CST Reason:Ready Message:}]
Now: 09-05 18:03:18 I did not find frequent status updates. Can you print the version information? # replace the pod name of clusterpedia clustersynchro-manager
$ kubectl -n clusterpedia-system exec {clustersynchro-manager-pod-name} -- clustersynchro-manager --version=raw In a previous commit, it did trigger frequent updates, but this has been fixed. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
These logs make me confused.At first I thought the cluster status was constantly changing(sync resources Or cluster healthy status),and I research the code and find the status of pediacluster is updated every 5s.See code https://github.com/clusterpedia-io/clusterpedia/blob/b06cc6d0f6f06af50269a9533202211552c63252/pkg/synchromanager/clustersynchro/cluster_monitor.go#L36
Do you need to optimize it? @Iceber
Beta Was this translation helpful? Give feedback.
All reactions