Class DaprClientGrpcInterceptors

java.lang.Object
io.dapr.internal.grpc.DaprClientGrpcInterceptors

public class DaprClientGrpcInterceptors extends Object
Class to be used as part of your service's client stub interceptor. Usage: myClientStub = DaprClientGrpcInterceptors.intercept(myClientStub);
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(String appId, T client)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(String appId, T client, TimeoutPolicy timeoutPolicy)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(String appId, T client, TimeoutPolicy timeoutPolicy, reactor.util.context.ContextView context)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(String appId, T client, reactor.util.context.ContextView context)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(T client)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(T client, TimeoutPolicy timeoutPolicy)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(T client, TimeoutPolicy timeoutPolicy, reactor.util.context.ContextView context)
    Adds all Dapr interceptors to a gRPC async stub.
    static <T extends io.grpc.stub.AbstractStub<T>>
    T
    intercept(T client, reactor.util.context.ContextView context)
    Adds all Dapr interceptors to a gRPC async stub.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DaprClientGrpcInterceptors

      public DaprClientGrpcInterceptors()
  • Method Details

    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(String appId, T client)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      appId - the appId to be invoked
      client - gRPC client
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(T client)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      client - gRPC client
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(String appId, T client, TimeoutPolicy timeoutPolicy)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      appId - the appId to be invoked
      client - gRPC client
      timeoutPolicy - timeout policy for gRPC call
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(T client, TimeoutPolicy timeoutPolicy)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      client - gRPC client
      timeoutPolicy - timeout policy for gRPC call
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(String appId, T client, reactor.util.context.ContextView context)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      appId - the appId to be invoked
      client - gRPC client
      context - Reactor context for tracing
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(T client, reactor.util.context.ContextView context)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      client - gRPC client
      context - Reactor context for tracing
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(T client, TimeoutPolicy timeoutPolicy, reactor.util.context.ContextView context)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      client - gRPC client
      timeoutPolicy - timeout policy for gRPC call
      context - Reactor context for tracing
      Returns:
      async client instance with interceptors
    • intercept

      public static <T extends io.grpc.stub.AbstractStub<T>> T intercept(String appId, T client, TimeoutPolicy timeoutPolicy, reactor.util.context.ContextView context)
      Adds all Dapr interceptors to a gRPC async stub.
      Type Parameters:
      T - async client type
      Parameters:
      appId - the appId to be invoked
      client - gRPC client
      timeoutPolicy - timeout policy for gRPC call
      context - Reactor context for tracing
      Returns:
      async client instance with interceptors