worker

package
v0.0.0-...-4046ec0 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Worker

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

func New

func New(
	id int,
	cache interfaces.CacheLoader,
	mappers interfaces.Mappers,
	logger *slog.Logger,
	wg *sync.WaitGroup,
	jobCh chan *dto.Job,
	errorCh chan error,
	publishCh chan *publisher.Publishing,
	stats *atomic.Int64,
	cfg *config.RabbitMQ,
) *Worker

func (*Worker) PublishResult

func (w *Worker) PublishResult(ctx context.Context, result dto.Result)

func (*Worker) PublishStatistics

func (w *Worker) PublishStatistics(ctx context.Context, count int64)

func (*Worker) Start

func (w *Worker) Start(ctx context.Context)

Jump to

Keyboard shortcuts

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