cron

package
v0.1.17 Latest Latest
Warning

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

Go to latest
Published: May 5, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Job

type Job struct {
	CronPattern string
	Name        string
	Task        func(ctx context.Context)
	// contains filtered or unexported fields
}

func NewJob

func NewJob(name, cronPattern string, task func(ctx context.Context), options ...JobOption) *Job

func (*Job) Start

func (job *Job) Start()

type JobOption

type JobOption func(job *Job)

func WithLogger

func WithLogger(logger log.Logger) JobOption

Jump to

Keyboard shortcuts

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