Class BinaryLogProvider

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    @Internal
    public abstract class BinaryLogProvider
    extends io.grpc.BinaryLog
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static io.grpc.MethodDescriptor.Marshaller<byte[]> BYTEARRAY_MARSHALLER  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      void close()  
      protected abstract io.grpc.ClientInterceptor getClientInterceptor​(java.lang.String fullMethodName, io.grpc.CallOptions callOptions)
      Returns a ClientInterceptor for binary logging.
      protected abstract io.grpc.ServerInterceptor getServerInterceptor​(java.lang.String fullMethodName)
      Returns a ServerInterceptor for binary logging.
      io.grpc.Channel wrapChannel​(io.grpc.Channel channel)
      Wraps a channel to provide binary logging on ClientCalls as needed.
      <ReqT,​RespT>
      io.grpc.ServerMethodDefinition<?,​?>
      wrapMethodDefinition​(io.grpc.ServerMethodDefinition<ReqT,​RespT> oMethodDef)
      Wraps a ServerMethodDefinition such that it performs binary logging if needed.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • BYTEARRAY_MARSHALLER

        public static final io.grpc.MethodDescriptor.Marshaller<byte[]> BYTEARRAY_MARSHALLER
    • Constructor Detail

      • BinaryLogProvider

        public BinaryLogProvider()
    • Method Detail

      • wrapChannel

        public final io.grpc.Channel wrapChannel​(io.grpc.Channel channel)
        Wraps a channel to provide binary logging on ClientCalls as needed.
        Specified by:
        wrapChannel in class io.grpc.BinaryLog
      • wrapMethodDefinition

        public final <ReqT,​RespT> io.grpc.ServerMethodDefinition<?,​?> wrapMethodDefinition​(io.grpc.ServerMethodDefinition<ReqT,​RespT> oMethodDef)
        Wraps a ServerMethodDefinition such that it performs binary logging if needed.
        Specified by:
        wrapMethodDefinition in class io.grpc.BinaryLog
      • getServerInterceptor

        @Nullable
        protected abstract io.grpc.ServerInterceptor getServerInterceptor​(java.lang.String fullMethodName)
        Returns a ServerInterceptor for binary logging. gRPC is free to cache the interceptor, so the interceptor must be reusable across calls. At runtime, the request and response marshallers are always Marshaller<InputStream>. Returns null if this method is not binary logged.
      • getClientInterceptor

        @Nullable
        protected abstract io.grpc.ClientInterceptor getClientInterceptor​(java.lang.String fullMethodName,
                                                                          io.grpc.CallOptions callOptions)
        Returns a ClientInterceptor for binary logging. gRPC is free to cache the interceptor, so the interceptor must be reusable across calls. At runtime, the request and response marshallers are always Marshaller<InputStream>. Returns null if this method is not binary logged.
      • close

        public void close()
                   throws java.io.IOException
        Throws:
        java.io.IOException