Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewProducer ¶
func NewProducer(params ProducerParams, opts ...ProducerOption) producer.Producer
NewProducer for NSQ.
func RegisterConsumer ¶
func RegisterConsumer(params ConsumerParams, opts ...ConsumerOption) error
RegisterConsumer for NSQ.
Types ¶
type ConsumerOption ¶ added in v1.59.0
type ConsumerOption interface {
// contains filtered or unexported methods
}
ConsumerOption for NSQ.
func WithConsumerLogger ¶ added in v1.59.0
func WithConsumerLogger(logger *zap.Logger) ConsumerOption
WithConsumerLogger for NSQ.
func WithConsumerMetrics ¶ added in v1.65.0
func WithConsumerMetrics(metrics *prometheus.ConsumerMetrics) ConsumerOption
WithConsumerMetrics for NSQ.
func WithConsumerTracer ¶ added in v1.59.0
func WithConsumerTracer(tracer opentracing.Tracer) ConsumerOption
WithConsumerConfig for NSQ.
type ConsumerParams ¶
type ConsumerParams struct { Lifecycle fx.Lifecycle Topic, Channel string Config *Config Handler handler.Handler Marshaller marshaller.Marshaller }
ConsumerParams for NSQ.
type ProducerOption ¶ added in v1.59.0
type ProducerOption interface {
// contains filtered or unexported methods
}
ProducerOption for NSQ.
func WithProducerBreaker ¶ added in v1.59.0
func WithProducerBreaker() ProducerOption
WithProducerBreaker for NSQ.
func WithProducerLogger ¶ added in v1.59.0
func WithProducerLogger(logger *zap.Logger) ProducerOption
WithProducerLogger for NSQ.
func WithProducerMetrics ¶ added in v1.65.0
func WithProducerMetrics(metrics *prometheus.ProducerMetrics) ProducerOption
WithProducerMetrics for NSQ.
func WithProducerRetry ¶ added in v1.59.0
func WithProducerRetry() ProducerOption
WithProducerRetry for NSQ.
func WithProducerTracer ¶ added in v1.59.0
func WithProducerTracer(tracer opentracing.Tracer) ProducerOption
WithProducerConfig for NSQ.
type ProducerParams ¶
type ProducerParams struct { Lifecycle fx.Lifecycle Config *Config Marshaller marshaller.Marshaller }
ProducerParams for NSQ.
Click to show internal directories.
Click to hide internal directories.