-
Notifications
You must be signed in to change notification settings - Fork 10k
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
Deprecate usage of gresolver.Address.Metadata
#19706
Comments
Hi @siyuanfoundation, I'd like to work on implementing this feature. I'll follow the gRPC resolver API changes to deprecate the Metadata usage in favor of Attributes. |
I just sent in a pr with the implementation in place. |
/assign @amosehiguese Thank you! |
We should also have use the supported fields in tests like #19702 |
Yeah, I noticed the tests still uses the metadata field, so my first attempt was to introduce the new field and make it backward compatible. However, now that you've mentioned the Metadata field should remain in the Endpoint, I will revert back to that only and handle the conversion process underneath. If this is fine, please signify. Lastly, I will love to mention that creating a new Attribute with the attributes.New(k, v any) to be used in the gresolver.Address Attribute field, takes in a key and a value as opposed to a single "any" argument(i.e the metadata passed) Would you say it's okay to use the up.Key for the key and the up.Endpoint.Metadata for the value? |
What would you like to be added?
Deprecate usage of
gresolver.Address.Metadata
in client/v3/naming/resolver/resolver.go, and addAttributes
field.Why is this needed?
gresolver.Address.Metadata
in grpc is deprecated, and should useAttributes
instead.https://github.com/grpc/grpc-go/blob/51d6a43ec59753d42ccd02bb12d2e9e40c164f0f/resolver/resolver.go#L117-L121
The text was updated successfully, but these errors were encountered: