Documentation ¶
Index ¶
- Variables
- func CheckConfig(cfg Config) error
- func Dial(addr string, opts ...grpc.DialOption) (*grpc.ClientConn, error)
- func Module() fx.Option
- func MustDial(addr string, opts ...grpc.DialOption) *grpc.ClientConn
- func NewGRPCServer(lc fx.Lifecycle, cfg Config, svcCfg svc_module.OptionalConfig, ...) (*grpc.Server, http_module.HttpOptions)
- func WithServerOptions(options ...grpc.ServerOption) fx.Option
- type Config
- type GRPCServerOptions
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultConfig = wrappedCfg{ Grpc: Config{ ListenAddr: "0.0.0.0", ListenPort: 4000, LogAllRequest: true, }, }
Functions ¶
func CheckConfig ¶
func Dial ¶
func Dial(addr string, opts ...grpc.DialOption) (*grpc.ClientConn, error)
func MustDial ¶
func MustDial(addr string, opts ...grpc.DialOption) *grpc.ClientConn
func NewGRPCServer ¶
func NewGRPCServer(lc fx.Lifecycle, cfg Config, svcCfg svc_module.OptionalConfig, svOpts grpcServerOptionsParams, logger *zap.Logger, ocfg optionalParams) (*grpc.Server, http_module.HttpOptions)
func WithServerOptions ¶
func WithServerOptions(options ...grpc.ServerOption) fx.Option
Types ¶
type Config ¶
type GRPCServerOptions ¶
type GRPCServerOptions struct { fx.Out Options []grpc.ServerOption `group:"grpc_server_option,flatten"` }
Click to show internal directories.
Click to hide internal directories.