stolostron / multicluster-global-hub

the main repository for the multicluster global hub
Apache License 2.0
21 stars 32 forks source link

:sparkles: Switch zap log for global hub manager #1185

Closed yanmxa closed 4 weeks ago

yanmxa commented 1 month ago

Summary

Related issue(s)

Fixes # https://issues.redhat.com/browse/ACM-13421, https://github.com/stolostron/multicluster-global-hub/issues/1178

Tests

2024-10-30T01:20:44.725Z        INFO    utils/utils.go:28       Go OS/Arch: linux/amd64
2024-10-30T01:20:44.725Z        INFO    utils/utils.go:29       Go Version: go1.22.5
2024-10-30T01:20:44.725Z        INFO    utils/utils.go:30       Git Commit: 0e0ccfa9
2024-10-30T01:20:44.744Z        INFO    cronjob/scheduler.go:68 set SyncLocalCompliance job     {"scheduleAt": "00:00"}
2024-10-30T01:20:44.744Z        INFO    cronjob/scheduler.go:77 set DataRetention jobscheduleAt00:00
2024-10-30T01:20:44.744Z        INFO    controller-runtime.metrics      server/server.go:208    Starting metrics server
I1030 01:20:44.744263       1 leaderelection.go:254] attempting to acquire leader lease multicluster-global-hub/multicluster-global-hub-manager-lock...
2024-10-30T01:20:44.744Z        INFO    controller-runtime.metrics      server/server.go:247    Serving metrics server  {"bindAddress": "0.0.0.0:8384", "secure": false}
I1030 01:23:06.543481       1 leaderelection.go:268] successfully acquired lease multicluster-global-hub/multicluster-global-hub-manager-lock
2024-10-30T01:23:06.543Z        INFO    cronjob/scheduler.go:86 start job scheduler
"ConfigMap", "worker count": 1}
2024-10-30T01:23:06.745Z        INFO    controller/controller.go:217    Starting workers        {"controller": "secret", "controllerGroup": "", "controllerKind": "Secret", "worker count": 1}
2024-10-30T01:23:06.745Z        INFO    controller/controller.go:217    Starting workers        {"controller": "backupPvcController", "controllerGroup": "", "controllerKind": "PersistentVolumeClaim", "worker count": 1}
2024-10-30T01:23:06.745Z        INFO    kafka-consumer  consumer/generic_consumer.go:84 transport consumer with cloudevents-kafka receiver
2024-10-30T01:23:06.750Z        INFO    dispatcher/transport_dispatcher.go:42   transport dispatcher starts dispatching received events...
2024-10-30T01:23:06.750Z        INFO    statistics      statistics/statistics.go:97     starting statistics
2024-10-30T01:23:06.750Z        INFO    dispatcher/conflation_dispatcher.go:64  starting dispatcher
2024-10-30T01:23:06.750Z        INFO    worker-pool     workerpool/worker_pool.go:38    connection stats        {"open connection(worker)": 1, "max": 10}
2024-10-30T01:23:06.750Z        INFO    worker-pool     workerpool/worker.go:46 started worker  {"WorkerID": 10}
...
2024-10-30T01:23:06.750Z        INFO    worker-pool     workerpool/worker.go:46 started worker  {"WorkerID": 5}
2024-10-30T01:23:06.750Z        INFO    worker-pool     workerpool/worker.go:46 started worker  {"WorkerID": 7}
2024-10-30T01:23:06.750Z        INFO    hub-management  hubmanagement/hub_management.go:73      hub management status switch frequency  {"interval": "2m0s"}
2024-10-30T01:23:06.750Z        INFO    controller/controller.go:175    Starting EventSource    {"controller": "migration-controller", "controllerGroup": "global-hub.open-cluster-management.io", "controllerKind": "ManagedClusterMigration", "source": "kind source: *v1alpha1.ManagedClusterMigration"}
2024-10-30T01:23:06.750Z        INFO    controller/controller.go:175    Starting EventSource    {"controller": "migration-controller", "controllerGroup": "global-hub.open-cluster-management.io", "controllerKind": "ManagedClusterMigration", "source": "kind source: *v1beta1.ManagedServiceAccount"}
2024-10-30T01:23:06.750Z        INFO    controller/controller.go:183    Starting Controller     {"controller": "migration-controller", "controllerGroup": "global-hub.open-cluster-management.io", "controllerKind": "ManagedClusterMigration"}
2024-10-30T01:23:06.754Z        INFO    kafka-consumer  consumer/generic_consumer.go:150        init consumeroffsets[]
2024-10-30T01:23:06.754Z        INFO    cloudevents     v2@v2.0.0-20240911135016-682f3a9684e4/protocol.go:166   Subscribing to topics: [^gh-status.*]
2024-10-30T01:23:06.853Z        INFO    controller/controller.go:217    Starting workers        {"controller": "migration-controller", "controllerGroup": "global-hub.open-cluster-management.io", "controllerKind": "ManagedClusterMigration", "worker count": 1}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.policy.localspec    conflator/element_complete.go:66        resetting element processed version     {"version": "0.1"}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.managedhub.heartbeat        conflator/element_complete.go:66        resetting element processed version     {"version": "0.0"}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.policy.localcompletecompliance      conflator/element_complete.go:66        resetting element processed version     {"version": "0.1"}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.policy.localcompliance      conflator/element_complete.go:66        resetting element processed version     {"version": "0.1"}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.managedcluster      conflator/element_complete.go:66        resetting element processed version     {"version": "0.1"}
2024-10-30T01:23:10.007Z        INFO    demo-hub-a.complete.managedhub.info     conflator/element_complete.go:66        resetting element processed version     {"version": "0.2"}
yanmxa commented 4 weeks ago

e2e setup error /test test-e2e

yanmxa commented 4 weeks ago

/override ci/prow/sonarcloud

openshift-ci[bot] commented 4 weeks ago

@yanmxa: Overrode contexts on behalf of yanmxa: ci/prow/sonarcloud

In response to [this](https://github.com/stolostron/multicluster-global-hub/pull/1185#issuecomment-2445671169): >/override ci/prow/sonarcloud 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-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.
yanmxa commented 4 weeks ago

/test test-e2e

yanmxa commented 4 weeks ago

/override "SonarCloud Code Analysis"

openshift-ci[bot] commented 4 weeks ago

@yanmxa: Overrode contexts on behalf of yanmxa: SonarCloud Code Analysis

In response to [this](https://github.com/stolostron/multicluster-global-hub/pull/1185#issuecomment-2445945957): >/override "SonarCloud Code Analysis" 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-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.
clyang82 commented 4 weeks ago

/lgtm

openshift-ci[bot] commented 4 weeks ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: clyang82, yanmxa

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: - ~~[OWNERS](https://github.com/stolostron/multicluster-global-hub/blob/main/OWNERS)~~ [clyang82,yanmxa] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
sonarcloud[bot] commented 4 weeks ago

Quality Gate Failed Quality Gate failed

Failed conditions
63.7% Coverage on New Code (required ≥ 70%)

See analysis details on SonarCloud

yanmxa commented 4 weeks ago

/override ci/prow/sonarcloud

openshift-ci[bot] commented 4 weeks ago

@yanmxa: Overrode contexts on behalf of yanmxa: ci/prow/sonarcloud

In response to [this](https://github.com/stolostron/multicluster-global-hub/pull/1185#issuecomment-2446058966): >/override ci/prow/sonarcloud 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-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.
yanmxa commented 4 weeks ago

/override "SonarCloud Code Analysis"

openshift-ci[bot] commented 4 weeks ago

@yanmxa: Overrode contexts on behalf of yanmxa: SonarCloud Code Analysis

In response to [this](https://github.com/stolostron/multicluster-global-hub/pull/1185#issuecomment-2446059424): >/override "SonarCloud Code Analysis" 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-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.