jobs

package
v0.0.0-...-afa1830 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2021 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetNotifPeriod

func GetNotifPeriod(frequency string) (time.Duration, error)

GetNotifPeriod translates a string to a time.Duration

Types

type BoxInfo

type BoxInfo struct {
	ID          string
	Title       string
	NewMessages int
}

BoxInfo model

type DigestInfo

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

DigestInfo model

type DigestJob

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

DigestJob contains connectors and configuration for the digest job

func NewDigestJob

func NewDigestJob(
	frequency, domain string,

	ssoDB *sql.DB,
	boxDB *sql.DB,
	redConn *redis.Client,

	emails email.Sender,
	templates email.Renderer,
) (*DigestJob, error)

NewDigestJob constructor

func (*DigestJob) SendDigests

func (dj *DigestJob) SendDigests(ctx context.Context) error

SendDigests checks users to notify and send them their digests

Source Files

  • digest_service.go
  • digests.go

Jump to

Keyboard shortcuts

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