Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // GRPCModule for fx. GRPCModule = fx.Options( fx.Provide(grpc.NewServer), fx.Provide(grpc.UnaryServerInterceptor), fx.Provide(grpc.StreamServerInterceptor), fx.Provide(gprometheus.NewServerMetrics), fx.Provide(gprometheus.NewClientMetrics), fx.Provide(gotel.NewTracer), ) // HTTPModule for fx. HTTPModule = fx.Options( fx.Provide(http.NewServer), fx.Provide(hprometheus.NewServerMetrics), fx.Provide(hprometheus.NewClientMetrics), fx.Provide(hotel.NewTracer), ) // NSQModule for fx. NSQModule = fx.Options( fx.Provide(nprometheus.NewProducerMetrics), fx.Provide(nprometheus.NewConsumerMetrics), fx.Provide(notel.NewTracer), fx.Provide(marshaller.NewMsgPack), ) // Module for fx. Module = fx.Options( GRPCModule, HTTPModule, NSQModule, fx.Invoke(Register), ) )
Functions ¶
Types ¶
type Config ¶
type Config struct { Port string `yaml:"port" json:"port" toml:"port"` GRPC grpc.Config `yaml:"grpc" json:"grpc" toml:"grpc"` HTTP http.Config `yaml:"http" json:"http" toml:"http"` NSQ nsq.Config `yaml:"nsq" json:"nsq" toml:"nsq"` }
Config for transport.
type RegisterParams ¶ added in v1.70.0
type RegisterParams struct { fx.In Lifecycle fx.Lifecycle Shutdowner fx.Shutdowner Config *Config HTTP *http.Server GRPC *grpc.Server }
RegisterParams for transport.
Click to show internal directories.
Click to hide internal directories.