Documentation
¶
Overview ¶
Package transport is the transport layer of the gRPC client SDK example. It owns the shared *grpc.ClientConn and lazily builds one grpcclientv1.Client per RPC, injecting the domain <-> protobuf codecs provided by the encoder and decoder sub-packages. Streaming is aggregated by the SDK transport, so callers see a unary endpoint. This mirrors the layering of the task_scheduler client.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DemoTransport ¶
type DemoTransport interface {
Echo() grpcclientv1.Client[string, string]
Download() grpcclientv1.Client[string, []byte]
}
DemoTransport defines the transport layer interface for the Demo service. Each method returns a fully configured grpcclientv1.Client bound to one RPC.
type Factory ¶
type Factory interface {
Demo() DemoTransport
}
Factory is the entry point of the transport layer.
func New ¶
func New(conn *grpc.ClientConn) Factory
New creates a transport Factory bound to the given client connection.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package decoder is the response-decoder layer of the gRPC client SDK example's transport.
|
Package decoder is the response-decoder layer of the gRPC client SDK example's transport. |
|
Package encoder is the request-encoder layer of the gRPC client SDK example's transport.
|
Package encoder is the request-encoder layer of the gRPC client SDK example's transport. |