Help us shape the future of Go! Take the 2026 Go Developer Survey

schedule

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package schedule evaluates unions of cron windows without running background jobs.

Index

Constants

View Source
const MaxDuration = 7 * 24 * time.Hour

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine

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

func Compile

func Compile(schedules []api.Schedule) (*Engine, error)

func (*Engine) At

func (e *Engine) At(now time.Time) Window

At caches upcoming window boundaries for one hour. Work and memory are bounded by 16 schedules and a 28-day horizon, including lookback. A zero End denotes a continuous union extending beyond the lookahead horizon.

type Window

type Window struct {
	Active     bool
	Start, End time.Time
}

Jump to

Keyboard shortcuts

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