Documentation
¶
Index ¶
- Variables
- func NewMessageEnqueuedEvent() *domain.Event
- func NewMessagesExportRequestedEvent(since, until time.Time) *domain.Event
- func NewSettingsUpdatedEvent() *domain.Event
- func NewWebhooksUpdatedEvent() *domain.Event
- type BlacklistOperation
- type Config
- type Event
- type Mode
- type Params
- type RetryOutcome
- type Service
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Module( "push", fx.Decorate(func(log *zap.Logger) *zap.Logger { return log.Named("push") }), fx.Provide( func(cfg Config, lc fx.Lifecycle) (c client, err error) { switch cfg.Mode { case ModeFCM: c, err = fcm.New(cfg.ClientOptions) case ModeUpstream: c, err = upstream.New(cfg.ClientOptions) default: return nil, errors.New("invalid push mode") } if err != nil { return nil, err } lc.Append(fx.Hook{ OnStart: func(ctx context.Context) error { return c.Open(ctx) }, OnStop: func(ctx context.Context) error { return c.Close(ctx) }, }) return c, nil }, ), fx.Provide( New, ), )
View Source
var NewEvent = domain.NewEvent
Functions ¶
func NewMessageEnqueuedEvent ¶
func NewMessagesExportRequestedEvent ¶ added in v1.17.0
func NewSettingsUpdatedEvent ¶ added in v1.23.0
func NewWebhooksUpdatedEvent ¶
Types ¶
type BlacklistOperation ¶ added in v1.21.0
type BlacklistOperation string
const ( BlacklistOperationAdded BlacklistOperation = "added" BlacklistOperationSkipped BlacklistOperation = "skipped" )
type RetryOutcome ¶ added in v1.21.0
type RetryOutcome string
const ( RetryOutcomeRetried RetryOutcome = "retried" RetryOutcomeMaxAttempts RetryOutcome = "max_attempts" )
Click to show internal directories.
Click to hide internal directories.