cron

package
v1.15.9 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2025 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	// Run starts the cron server, blocking until the context is canceled.
	Run(ctx context.Context) error

	// Client returns a client to schedule jobs with the underlying cron
	// framework and database. Blocks until Etcd and the Cron library are ready.
	Client(ctx context.Context) (api.Interface, error)

	// JobsWatch adds a watch for jobs to the connection pool.
	JobsWatch(*schedulerv1pb.WatchJobsRequestInitial, schedulerv1pb.Scheduler_WatchJobsServer) (context.Context, error)

	// HostsWatch adds a watch for hosts to the connection pool.
	HostsWatch(schedulerv1pb.Scheduler_WatchHostsServer) error
}

Interface manages the cron framework, exposing a client to schedule jobs.

func New

func New(opts Options) Interface

type Options

type Options struct {
	ID      string
	Host    *schedulerv1pb.Host
	Healthz healthz.Healthz
	Etcd    etcd.Interface
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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