Package io.grpc.auth
Class ClientAuthInterceptor
- java.lang.Object
-
- io.grpc.auth.ClientAuthInterceptor
-
- All Implemented Interfaces:
ClientInterceptor
@Deprecated public final class ClientAuthInterceptor extends Object implements ClientInterceptor
Deprecated.useMoreCallCredentials.from(Credentials)
instead.Client interceptor that authenticates all calls by binding header data provided by a credential. Typically this will populate the Authorization header but other headers may also be filled out.Uses the new and simplified Google auth library: https://github.com/google/google-auth-library-java
-
-
Constructor Summary
Constructors Constructor Description ClientAuthInterceptor(com.google.auth.Credentials credentials, Executor executor)
Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description <ReqT,RespT>
ClientCall<ReqT,RespT>interceptCall(MethodDescriptor<ReqT,RespT> method, CallOptions callOptions, Channel next)
Deprecated.
-
-
-
Constructor Detail
-
ClientAuthInterceptor
public ClientAuthInterceptor(com.google.auth.Credentials credentials, Executor executor)
Deprecated.
-
-
Method Detail
-
interceptCall
public <ReqT,RespT> ClientCall<ReqT,RespT> interceptCall(MethodDescriptor<ReqT,RespT> method, CallOptions callOptions, Channel next)
Deprecated.Description copied from interface:ClientInterceptor
InterceptClientCall
creation by thenext
Channel
.Many variations of interception are possible. Complex implementations may return a wrapper around the result of
next.newCall()
, whereas a simpler implementation may just modify the header metadata prior to returning the result ofnext.newCall()
.next.newCall()
must not be called under a differentContext
other than the currentContext
. The outcome of such usage is undefined and may cause memory leak due to unbounded chain ofContext
s.- Specified by:
interceptCall
in interfaceClientInterceptor
- Parameters:
method
- the remote method to be called.callOptions
- the runtime options to be applied to this call.next
- the channel which is being intercepted.- Returns:
- the call object for the remote operation, never
null
.
-
-