Merge pull request #98252 from lala123912/log_format_audit

staging/src/k8s.io/apiserver/pkg/audit/policy/reader.go: migrate logs to structured logging
This commit is contained in:
Kubernetes Prow Robot 2021-01-21 02:05:01 -08:00 committed by GitHub
commit 5856883274
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -85,6 +85,7 @@ func LoadPolicyFromBytes(policyDef []byte) (*auditinternal.Policy, error) {
if policyCnt == 0 {
return nil, fmt.Errorf("loaded illegal policy with 0 rules")
}
klog.V(4).Infof("Loaded %d audit policy rules", policyCnt)
klog.V(4).InfoS("Load audit policy rules success", "policyCnt", policyCnt)
return policy, nil
}