背景
gRPCにはクライアントとサーバとの通信を抽象化したChannelという仕組みがあります。
GRPC_GO_LOG_SEVERITY_LEVEL=info
を有効にした際に出てくる
[core] Channel Created [core] parsed scheme: "" [core] scheme "" not registered, fallback to default scheme [core] ccResolverWrapper: sending update to cc: {[{localhost:8080 <nil> 0 <nil>}] <nil> <nil>} [core] Resolver state updated: {Addresses:[{Addr:localhost:8080 ServerName: Attributes:<nil> Type:0 Metadata:<nil>}] ServiceConfig:<nil> Attributes:<nil>} (resolver returned new addresses) [core] ClientConn switching balancer to "pick_first" [core] Channel switches to new LB policy "pick_first" [core] Subchannel Created [core] Subchannel(id:2) created [core] Subchannel Connectivity change to CONNECTING [core] Subchannel picks a new address "localhost:8080" to connect [core] Channel Connectivity change to CONNECTING [core] CPU time info is unavailable on non-linux or appengine environment. [core] Subchannel Connectivity change to READY [core] Channel Connectivity change to READY ... [core] Channel Connectivity change to SHUTDOWN [core] Subchannel Connectivity change to SHUTDOWN [core] Subchannel Deleted [core] Subchanel(id:2) deleted [core] Channel Deleted
Channel、Subchannelのような概念もあるので、理解のため一度整理します。
続きを読む