cron

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2026 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseSchedule

func ParseSchedule(configuration string) (cron.Schedule, *time.Location, error)

ParseSchedule parses the cron schedule and timezone from a trigger's Configuration JSON string. The returned location is never nil — it defaults to UTC when no timezone is configured. Callers should enumerate logical dates using times anchored to the returned location so that date boundaries respect the job's configured timezone.

Types

type Cron

type Cron struct {
	trigger.Trigger
	// contains filtered or unexported fields
}

func New

func New(t *models.Trigger) (*Cron, error)

func (*Cron) Fire

func (c *Cron) Fire(ctx context.Context) error

func (*Cron) ID

func (c *Cron) ID() uuid.UUID

func (*Cron) Listen

func (c *Cron) Listen(ctx context.Context)

Jump to

Keyboard shortcuts

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