struct GRPC::CallInfo

Overview

CallInfo carries metadata about an in-flight RPC call passed to interceptors. Interceptors should use this instead of parsing raw strings.

Example: def call(info : GRPC::CallInfo, request, ctx, next_call) STDERR.puts "→ #{info.method_path} (#{info.kind})" next_call.call(info.method_path, request, ctx) end

Defined in:

grpc/interceptor.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(method_path : String, kind : RPCKind) #

[View source]

Instance Method Detail

def kind : RPCKind #

Streaming kind of this RPC


[View source]
def method : String #

method returns the method name portion of the path, e.g. "SayHello"


[View source]
def method_path : String #

Full gRPC method path, e.g. "/helloworld.Greeter/SayHello"


[View source]
def service : String #

service returns the service portion of the path, e.g. "helloworld.Greeter"


[View source]