cron

package
v1.0.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CronSource

type CronSource struct {
	Schedule string
	Payload  string
	// contains filtered or unexported fields
}

CronSource implements the hermod.Source interface for scheduled triggers.

func NewCronSource

func NewCronSource(schedule, payload string) *CronSource

NewCronSource creates a new CronSource.

func (*CronSource) Ack

func (s *CronSource) Ack(ctx context.Context, msg hermod.Message) error

Ack is a no-op for cron.

func (*CronSource) Close

func (s *CronSource) Close() error

Close stops the cron scheduler.

func (*CronSource) Ping

func (s *CronSource) Ping(ctx context.Context) error

Ping checks if the schedule is valid.

func (*CronSource) Read

func (s *CronSource) Read(ctx context.Context) (hermod.Message, error)

Read blocks until the cron trigger fires.

Jump to

Keyboard shortcuts

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