scheduledevents

package
v0.30.1 Latest Latest
Warning

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

Go to latest
Published: May 23, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NumCurrentlyProcessing

func NumCurrentlyProcessing() int64

func NumScheduledEvents

func NumScheduledEvents(client *redis.Client) (int, error)

func RegisterEventHandler

func RegisterEventHandler(evt string, handler EvtHandler)

func RemoveEvent

func RemoveEvent(client *redis.Client, evt, data string) error

func Run

func Run()

Checks for and handles scheduled events every minute

func ScheduleEvent

func ScheduleEvent(client *redis.Client, evt, data string, when time.Time) error

func Stop

func Stop(wg *sync.WaitGroup)

Types

type EvtHandler

type EvtHandler func(evt string) error

If error is not nil, it will be added back

Jump to

Keyboard shortcuts

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