Conversation
io.grpc.Uri is an implementation of RFC 3986 tailored for grpc-java's needs. It lifts some of the limitations of java.net.URI that currently prevent us from resolving target URIs like intent:#Intent;...
ejona86
left a comment
There was a problem hiding this comment.
This looks nice. It's slightly strange you can't create a builder directly, but that'd just have you do Uri.create("myscheme:").toBuilder(), which seems pretty clear and guarantees there is a scheme.
Thanks! Actually the Builder() ctor is public. My intention is for users to write code like: Maybe there should be a public static newBuilder() method instead to match Attributes and CreateSubchannelArgs and MethodDescriptor ... ? |
For consistency with the builder pattern elsewhere in grpc-java
|
Ah, I see. Yeah, it would match our other APIs more to have a |
io.grpc.Uriis an implementation of RFC 3986 tailored for grpc-java's needs. It lifts some of the limitations ofjava.net.URIthat currently prevent us from resolving target URIs likeintent:#Intent;...See #12244 for more.Marked
@Internalfor now but the plan is to eventually use this to replacejava.net.URIin our public APIs such as NameResolver.Factory.