-
Bug
-
Resolution: Done
-
Undefined
-
ACM 2.8.4
-
None
-
1
-
False
-
None
-
False
-
-
-
GRC Sprint 2024-06
-
Moderate
-
No
Description of problem:
The template sync controller reconciles every time a policy template is updated. The config-policy-controller updates the `lastEvaluated` status on the ConfigurationPolicy, which by default is every 10 seconds. This can get noisy if you have a lot of policy templates and can cause important logs to be lost when debugging an issue since the logs rollover at a certain point.
Logs such as this are not useful and instead, we should only log when something changes or is unexpected:
```
024-03-07T19:32:32.713106056Z 2024-03-07T19:32:32.713Z info policy-template-sync templatesync/template_sync.go:98 Reconciling the Policy
2024-03-07T19:32:32.717219357Z 2024-03-07T19:32:32.717Z info policy-template-sync templatesync/template_sync.go:805 Existing object matches the policy template
{"Request.Namespace": "cluster", "Request.Name": "open-cluster-management.policy", "template": "policy"}2024-03-07T19:32:32.720587809Z 2024-03-07T19:32:32.720Z info policy-template-sync templatesync/template_sync.go:805 Existing object matches the policy template
{"Request.Namespace": "cluster", "Request.Name": "open-cluster-management.policy", "template": "policy"}2024-03-07T19:32:32.723474962Z 2024-03-07T19:32:32.723Z info policy-template-sync templatesync/template_sync.go:805 Existing object matches the policy template
{"Request.Namespace": "cluster", "Request.Name": "open-cluster-management.policy", "template": "policy"}2024-03-07T19:32:32.741347887Z 2024-03-07T19:32:32.741Z info policy-template-sync templatesync/template_sync.go:875 Completed the reconciliation
{"Request.Namespace": "cluster", "Request.Name": "open-cluster-management.policy"}```
Version-Release number of selected component (if applicable):
2.8.4
How reproducible:
Steps to Reproduce:
- ...
Actual results:
Expected results:
Additional info:
- clones
-
ACM-10403 Reduce policy template sync controller log noise
- Closed
- links to
-
RHBA-2024:130865 Red Hat Advanced Cluster Management 2.10.3 bug fixes and container updates