Documentation ¶
Overview ¶
Package server provides ...
Package server provides ...
Index ¶
Constants ¶
View Source
const ( // recover from panic FlagRecover = 1 << iota // tracing with opentelemetry FlagTracing // metric FlagMetric // client secure for tls FlagSecure ServerStdFlag = FlagRecover ClientStdFlag = 0 )
flag list
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DialOption ¶
type DialOption func(opts *DialOptions)
DialOption client dial option
func WithEndpoint ¶
func WithEndpoint(addr string) DialOption
WithEndpoint connect to server endpoint
func WithRegistry ¶
func WithRegistry(reg registry.Registry) DialOption
WithRegistry registry for discovery
type DialOptions ¶
type DialOptions struct { // client connect to endpoint Endpoint string // connect timeout Timeout time.Duration // user-agent UserAgent string // other options for implementations of the interface // can be stored in a context Context context.Context // discovery registry to server Registry registry.Registry // client flag Flag FlagOption }
DialOptions client dial Options
type ServerOption ¶
type ServerOption func(opts *ServerOptions)
ServerOption server option
func WithOptions ¶
func WithOptions(sopts ...grpc.ServerOption) ServerOption
WithOptions gRPC server option
type ServerOptions ¶
type ServerOptions struct { // server listen network tcp/udp Network string // server run address Address string // handler for http server Handler http.Handler // Options for gRPC server Options []grpc.ServerOption // server flag Flag FlagOption }
ServerOptions server Options
Directories ¶
Path | Synopsis |
---|---|
Package grpcx provides ...
|
Package grpcx provides ... |
clientinterceptor
Package clientinterceptor provides ...
|
Package clientinterceptor provides ... |
resolver
Package resolver provides ...
|
Package resolver provides ... |
serverinterceptor
Package serverinterceptor provides ...
|
Package serverinterceptor provides ... |
Package httpx provides ...
|
Package httpx provides ... |
handler
Package handler provides ...
|
Package handler provides ... |
Click to show internal directories.
Click to hide internal directories.