File tree Expand file tree Collapse file tree
binder/src/main/java/io/grpc/binder Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -45,11 +45,4 @@ private ApiConstants() {}
4545 */
4646 public static final NameResolver .Args .Key <UserHandle > TARGET_ANDROID_USER =
4747 NameResolver .Args .Key .create ("target-android-user" );
48-
49- /**
50- * The authentic ServiceInfo for an {@link io.grpc.EquivalentAddressGroup} of {@link
51- * AndroidComponentAddress}es, in case a {@link NameResolver} has already looked it up.
52- */
53- public static final Attributes .Key <ServiceInfo > TARGET_SERVICE_INFO =
54- Attributes .Key .create ("target-service-info" );
5548}
Original file line number Diff line number Diff line change @@ -670,19 +670,15 @@ public synchronized Runnable start(ManagedClientTransport.Listener clientTranspo
670670
671671 @ GuardedBy ("this" )
672672 private void preAuthorizeServer () {
673- Attributes eagAttrs = checkNotNull (attributes .get (GrpcAttributes .ATTR_CLIENT_EAG_ATTRS ));
674- ServiceInfo serviceInfo = eagAttrs .get (ApiConstants .TARGET_SERVICE_INFO );
675- if (serviceInfo == null ) {
676- serviceInfo = serviceBinding .resolve ();
677- }
673+ ServiceInfo serviceInfo = serviceBinding .resolve ();
678674
679675 // It's unlikely, but in theory the server identity/existence represented by this ServiceInfo
680676 // could change by the time we actually bind/connect. It doesn't matter though, because:
681677 // - If pre-auth fails (but would succeed for the new identity), grpc-core will retry
682678 // against the replacement server using a new instance of BinderClientTransport.
683679 // - If pre-auth succeeds (but would fail for the new identity), we might incorrectly bind
684- // to an unauthorized server, but we'll check the SecurityPolicy again in SETUP_TRANSPORT
685- // against the actual/new server's identity .
680+ // to an unauthorized server, but we'll notice when we the SecurityPolicy again as part of the
681+ // usual handshake .
686682 if (serviceInfo == null ) {
687683 preAuthResultFuture =
688684 Futures .immediateFuture (
You can’t perform that action at this time.
0 commit comments