grpc

package
v1.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2021 License: Unlicense Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ServerModule for fx.
	ServerModule = fx.Provide(NewServer)

	// ServerOptionsModule for fx.
	ServerOptionsModule = fx.Provide(NewServerOptions)

	// Module for fx.
	Module = fx.Options(ServerModule, ServerOptionsModule)
)

Functions

func NewClient

func NewClient(context context.Context, host string, logger *zap.Logger, opts ...grpc.DialOption) (*grpc.ClientConn, error)

NewClient to host for gRPC.

func NewServer

func NewServer(lc fx.Lifecycle, s fx.Shutdowner, cfg *config.Config, logger *zap.Logger, opts []grpc.ServerOption) *grpc.Server

NewServer for gRPC.

func NewServerOptions

func NewServerOptions() []grpc.ServerOption

NewServerOptions is blank to satisfy the dep of []grpc.ServerOption This can be changed by implementers to provide options.

Types

This section is empty.

Directories

Path Synopsis
logger
zap
trace

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL