schedule

package
v0.1.39 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const TriggerID = "schedule"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Users    map[string][]string `` /* 160-byte string literal not displayed */
	Interval time.Duration       `yaml:"interval,omitempty" default:"30m" doc:"Интервал синхронизации."`
}

type Trigger

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

func NewTrigger

func NewTrigger(params TriggerParams) (*Trigger, error)

func (*Trigger) ID

func (t *Trigger) ID() string

func (*Trigger) Run

func (t *Trigger) Run(ctx triggers.Context, job triggers.Jobs)

type TriggerParams

type TriggerParams struct {
	Clock  based.Clock `validate:"required"`
	Config *Config     `validate:"required"`
}

Jump to

Keyboard shortcuts

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