Documentation ¶
Index ¶
- func NewComponentSender(client mrstorage.DBConnManager, noticeTable mrsql.DBTableInfo, ...) *produce.NoticeSender
- func NewComponentService(client mrstorage.DBConnManager, mailerAPI mrnotifier.MailerAPI, ...) (mrrun.Process, []mrworker.Task)
- type ServiceOption
- func WithChangeLimit(value uint32) ServiceOption
- func WithChangeRetryDelayed(value time.Duration) ServiceOption
- func WithChangeRetryTimeout(value time.Duration) ServiceOption
- func WithCleanLimit(value uint32) ServiceOption
- func WithDefaultLang(value string) ServiceOption
- func WithSendProcessorOpts(value ...consume.Option) ServiceOption
- func WithTaskChangeFromToRetryOpts(value ...task.Option) ServiceOption
- func WithTaskCleanNoticesOpts(value ...task.Option) ServiceOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewComponentSender ¶
func NewComponentSender( client mrstorage.DBConnManager, noticeTable mrsql.DBTableInfo, queueTable mrsql.DBTableInfo, eventEmitter mrsender.EventEmitter, opts ...produce.Option, ) *produce.NoticeSender
NewComponentSender - создаёт отправителя сообщений получателям.
func NewComponentService ¶
func NewComponentService( client mrstorage.DBConnManager, mailerAPI mrnotifier.MailerAPI, eventEmitter mrsender.EventEmitter, errorHandler mrcore.ErrorHandler, noticeTable mrsql.DBTableInfo, queueTable mrsql.DBTableInfo, templateTableName string, templateVarName string, opts ...ServiceOption, ) (mrrun.Process, []mrworker.Task)
NewComponentService - создаёт сервис для обработки уведомлений и связанных с ним задачи.
Types ¶
type ServiceOption ¶
type ServiceOption func(o *serviceOptions)
ServiceOption - настройка объекта ComponentService.
func WithChangeLimit ¶
func WithChangeLimit(value uint32) ServiceOption
WithChangeLimit - устанавливает опцию changeLimit для ComponentService.
func WithChangeRetryDelayed ¶
func WithChangeRetryDelayed(value time.Duration) ServiceOption
WithChangeRetryDelayed - устанавливает опцию changeRetryDelayed для ComponentService.
func WithChangeRetryTimeout ¶
func WithChangeRetryTimeout(value time.Duration) ServiceOption
WithChangeRetryTimeout - устанавливает опцию changeRetryTimeout для ComponentService.
func WithCleanLimit ¶
func WithCleanLimit(value uint32) ServiceOption
WithCleanLimit - устанавливает опцию cleanLimit для ComponentService.
func WithDefaultLang ¶
func WithDefaultLang(value string) ServiceOption
WithDefaultLang - устанавливает опцию defaultLang для ComponentService.
func WithSendProcessorOpts ¶
func WithSendProcessorOpts(value ...consume.Option) ServiceOption
WithSendProcessorOpts - устанавливает опцию sendProcessor для ComponentService.
func WithTaskChangeFromToRetryOpts ¶
func WithTaskChangeFromToRetryOpts(value ...task.Option) ServiceOption
WithTaskChangeFromToRetryOpts - устанавливает опцию taskChangeFromToRetry для ComponentService.
func WithTaskCleanNoticesOpts ¶
func WithTaskCleanNoticesOpts(value ...task.Option) ServiceOption
WithTaskCleanNoticesOpts - устанавливает опцию taskCleanNotices для ComponentService.