scheduler

package
v0.0.0-...-a8e4d9d Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2020 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const ProgramName = "scheduler"

Variables

This section is empty.

Functions

func Main

func Main()

Types

type LiveSchedule

type LiveSchedule struct {
	Schedule    domain.Schedulable
	ActivityBus activity.Sink
}

func (*LiveSchedule) CreateOperation

func (self *LiveSchedule) CreateOperation(db *sqlx.DB) error

func (*LiveSchedule) Monitor

func (self *LiveSchedule) Monitor(db *sqlx.DB)

func (*LiveSchedule) Terminate

func (self *LiveSchedule) Terminate(c chan bool)

func (*LiveSchedule) WaitDuration

func (self *LiveSchedule) WaitDuration() time.Duration

type Pool

type Pool struct {
	sync.Mutex
	DB      *sqlx.DB
	Members map[string]LiveSchedule
}

func (*Pool) Add

func (self *Pool) Add(db *sqlx.DB, s domain.Schedulable, activityBus activity.Sink)

func (*Pool) Remove

func (self *Pool) Remove(uuid string)

func (*Pool) ToString

func (self *Pool) ToString() string

type SerializedNotification

type SerializedNotification struct {
	Table string           `json:"table"`
	New   *domain.Schedule `json:"new"`
	Old   *domain.Schedule `json:"old"`
}

Jump to

Keyboard shortcuts

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