notifi

package
v0.9.3 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StreamName = "NOTIFI"

	BaseSubject events.Subject = "notifi"

	// User notifications topic
	UserTopic events.Topic = "user"
	// Job event topic
	JobTopic events.Topic = "job"
	// System event topic
	SystemTopic events.Topic = "sys"
)

Variables

This section is empty.

Functions

func SplitSubject

func SplitSubject(in string) (events.Subject, events.Topic, []string)

Types

type INotifi

type INotifi interface {
	NotifyUser(ctx context.Context, not *notifications.Notification) error
}

func New

func New(p Params) INotifi

type Notifi

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

func (*Notifi) NotifyUser

func (n *Notifi) NotifyUser(ctx context.Context, not *notifications.Notification) error

type Params

type Params struct {
	fx.In

	LC     fx.Lifecycle
	Logger *zap.Logger
	DB     *sql.DB
	JS     *events.JSWrapper
}

Jump to

Keyboard shortcuts

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