nsq

package
v1.18.1 Latest Latest
Warning

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

Go to latest
Published: May 12, 2021 License: Unlicense Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ConfigModule for fx.
	ConfigModule = fx.Options(fx.Provide(NewConfig))

	// Module for fx.
	Module = fx.Options(ConfigModule)
)

Functions

func NewConfig

func NewConfig() *nsq.Config

NewConfig for NSQ.

func NewProducer

func NewProducer(lc fx.Lifecycle, params *ProducerParams) (producer.Producer, error)

NewProducer for NSQ.

func RegisterConsumer

func RegisterConsumer(lc fx.Lifecycle, params *ConsumerParams) error

RegisterConsumer for NSQ.

Types

type ConsumerParams

type ConsumerParams struct {
	SystemConfig *config.Config
	NSQConfig    *nsq.Config
	Logger       *zap.Logger
	Topic        string
	Channel      string
	Handler      handler.Handler
}

ConsumerParams for NSQ.

type ProducerParams

type ProducerParams struct {
	SystemConfig *config.Config
	NSQConfig    *nsq.Config
	Logger       *zap.Logger
}

ProducerParams for NSQ.

Directories

Path Synopsis
logger
zap
trace

Jump to

Keyboard shortcuts

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