-
Notifications
You must be signed in to change notification settings - Fork 38.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix structured logs for pkg/kubelet/network/dns/dns.go #100393
Conversation
pkg/kubelet/network/dns/dns.go
Outdated
log := fmt.Sprintf("Search Line limits were exceeded, some search paths have been omitted, the applied search line is: %s", strings.Join(composedSearch, " ")) | ||
c.recorder.Event(pod, v1.EventTypeWarning, "DNSConfigForming", log) | ||
klog.ErrorS(nil, "eventlog", log) | ||
log := fmt.Errorf("Search Line limits were exceeded, some search paths have been omitted, the applied search line is: %s", strings.Join(composedSearch, " ")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we change the name to avoid confusion?
log := fmt.Errorf("Search Line limits were exceeded, some search paths have been omitted, the applied search line is: %s", strings.Join(composedSearch, " ")) | |
err := fmt.Errorf("Search Line limits were exceeded, some search paths have been omitted, the applied search line is: %s", strings.Join(composedSearch, " ")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
Signed-off-by: Aditi Sharma <adi.sky17@gmail.com>
/lgtm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/kind bug
/priority important-longterm
/triage accepted
/lgtm
/milestone v1.21 Small change that fixes a bug introduced by structured logging migration. |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: adisky, derekwaynecarr 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:
Approvers can indicate their approval by writing |
/retest k8s.io/kubernetes/test/integration/apiserver/admissionwebhook: TestMutatingWebhookResetsInvalidManagedFields |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Fix structured logs for pkg/kubelet/network/dns/dns.go
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
This is caught by the linter update we are doing here kubernetes/klog#229, Its also to make sure we are adding correct checks in linter.
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:
/sig instrumentation