F5Networks / k8s-bigip-ctlr

Repository for F5 Container Ingress Services for Kubernetes & OpenShift.
Apache License 2.0
357 stars 195 forks source link

RFE: multicluster preview: indicate cluster in messages #2996

Closed alonsocamaro closed 7 months ago

alonsocamaro commented 1 year ago

Title

RFE: multicluster preview: indicate cluster in messages

Description

I´m testing the multicluster preview and I´m getting the following messages, certainly because of a miss-configuration.

E0725 08:07:15.592818       1 reflector.go:138] github.com/F5Networks/k8s-bigip-ctlr/pkg/controller/informers.go:1325: Failed to watch *v1.Node: failed to list *v1.Node: Unauthorized
E0725 08:07:25.725270       1 reflector.go:138] github.com/F5Networks/k8s-bigip-ctlr/pkg/controller/multiClusterInformers.go:35: Failed to watch *v1.Service: failed to list *v1.Service: Unauthorized
E0725 08:07:28.830531       1 reflector.go:138] github.com/F5Networks/k8s-bigip-ctlr/pkg/controller/multiClusterInformers.go:43: Failed to watch *v1.Pod: failed to list *v1.Pod: Unauthorized

but it is not defined in which cluster this is happening.

Actual Problem

It is not possible to determine in which cluster this auth failure is happening by checking CIS logs

Solution Proposed

Please include cluster name when showing any message that refers to any cluster operation. Not only to the messages above.

Another example of this is shown next:

2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/deployer-dockercfg-mnwdt
2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/default-dockercfg-j6fzf
2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/deployer-token-kvmv7
2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/default-token-nw5ng
2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/builder-token-2pt9n
2023/07/25 10:57:37 [DEBUG] Enqueueing Secrets: cafe/builder-dockercfg-b56bs
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/shell-demo
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/coffee-6dcfd99c7b-5972r
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/tea-747c94b84b-h4gps
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/mocha-6c75f84c74-wr9r7
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/mocha-6c75f84c74-28x8v
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/tea-747c94b84b-gp49z
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/coffee-6dcfd99c7b-98f7q
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/coffee-6dcfd99c7b-prqwm
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/tea-747c94b84b-hvrw8
2023/07/25 10:57:37 [DEBUG] Enqueueing pod: cafe/mocha-6c75f84c74-dpzsg

where it is not known which cluster is referring about

trinaths commented 1 year ago

Created [CONTCNTR-4090] for internal tracking.

trinaths commented 7 months ago

Closed as completed.