eventproducer

package
v0.0.0-...-23ae872 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	QueueConnection    string `env:"RABBITMQ_CONNECTION,default=amqp://guest:guest@localhost:5672/"`
	QueueEventExchange string `env:"RABBITMQ_EVENT_EXCHANGE,default=Events"`
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func New

func New(config Config, log *logrus.Logger) (*Service, error)

func (*Service) PublishEvent

func (s *Service) PublishEvent(ctx context.Context, userId int64, shardId string, event model.Event) error

func (*Service) Run

func (s *Service) Run(ctx context.Context) error

Run Group task

func (*Service) Shutdown

func (s *Service) Shutdown(ctx context.Context) error

Shutdown Group task gracefully shutdown

Jump to

Keyboard shortcuts

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