-
Notifications
You must be signed in to change notification settings - Fork 111
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 missing service info #1444
Fix missing service info #1444
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1444 +/- ##
==========================================
+ Coverage 76.90% 80.94% +4.04%
==========================================
Files 149 149
Lines 15250 15252 +2
==========================================
+ Hits 11728 12346 +618
+ Misses 2906 2298 -608
+ Partials 616 608 -8
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
Good stuff!
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.
Good catch!
pkg/internal/kube/store.go
Outdated
if serviceInfo, ok := s.otelServiceInfoByIP[ip]; ok { | ||
return serviceInfo.Name, serviceInfo.Namespace | ||
} |
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.
NIT: This operation is read-only. Why do you wrap into the mutex Write lock?
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.
I think you are right, we don't need that one under the lock, the read after was important to be inside the write lock.
This PR fixes two bugs in the k8s service discovery:
Closes #933
Closes #1426
I'll backport this to 1.9