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(opts WorkerOptions) (*Worker, error)
func (*Worker) AddHandler ¶
func (w *Worker) AddHandler(handler grouphandler.GroupEventHandler)
AddHandler adds an additional handler to the list of event handlers. Handlers are called in the order they are added and run after the built in handlers. In the case of any handler returning an error, the event will be retried so it is important that all handlers are idempotent.
type WorkerOptions ¶
type WorkerOptions struct {
SystemEventsTopic string
Router router.Options
EventBus eventbus.Publisher
Logger *slog.Logger
BillingAdapter billing.Adapter
BillingService billing.Service
BillingSubscriptionSyncHandler *billingworkersubscription.Handler
SubscriptionService subscription.Service
}
func (WorkerOptions) Validate ¶
func (w WorkerOptions) Validate() error
Click to show internal directories.
Click to hide internal directories.