-
Couldn't load subscription status.
- Fork 4.6k
xds/internal: remove Generic resource Decoder and add concrete functions #8652
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
base: master
Are you sure you want to change the base?
xds/internal: remove Generic resource Decoder and add concrete functions #8652
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #8652 +/- ##
==========================================
+ Coverage 81.21% 82.94% +1.72%
==========================================
Files 416 416
Lines 41002 32240 -8762
==========================================
- Hits 33298 26740 -6558
+ Misses 6226 4110 -2116
+ Partials 1478 1390 -88
🚀 New features to boost your workflow:
|
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.
Looks mostly good. Just some minor nits this time around.
| } | ||
|
|
||
| func (c *clientImpl) WatchResourceV2(typeURL, resourceName string, watcher xdsclient.ResourceWatcher) (cancel func()) { | ||
| func (c *clientImpl) WatchResource(typeURL, resourceName string, watcher xdsclient.ResourceWatcher) (cancel func()) { |
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 it is safe to just remove this method all together since this just calls the XDSClient method with the same signature and XDSClient is embedded in clientImpl so the call to WatchResource should implicitly call the function on XDSClient. Let me know if it is not the case and I am missing something.
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.
You are right. This can be completely removed.
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
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.
LGTM, modulo the one comment from Eshita.
| } | ||
|
|
||
| func (c *clientImpl) WatchResourceV2(typeURL, resourceName string, watcher xdsclient.ResourceWatcher) (cancel func()) { | ||
| func (c *clientImpl) WatchResource(typeURL, resourceName string, watcher xdsclient.ResourceWatcher) (cancel func()) { |
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.
You are right. This can be completely removed.
Addresses: #8381
RELEASE NOTES: None