https://github.com/aragaer/scheduler
An application used for scheduling delayed and/or periodic events
https://github.com/aragaer/scheduler
golang json periodic-repeats scheduling
Last synced: about 2 months ago
JSON representation
An application used for scheduling delayed and/or periodic events
- Host: GitHub
- URL: https://github.com/aragaer/scheduler
- Owner: aragaer
- License: mit
- Created: 2018-01-03T20:17:10.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-01-27T19:16:46.000Z (over 8 years ago)
- Last Synced: 2025-01-23T09:28:28.958Z (over 1 year ago)
- Topics: golang, json, periodic-repeats, scheduling
- Language: Go
- Homepage:
- Size: 29.3 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Scheduler
An application used for scheduling "events". Each event is a string that is printed to standard output.
Controlled by sending JSON commands to standard input
## Command format
Each command is a single-line JSON (no newlines must be within messages) ending with a newline. Each command must have the mandatory `command` field which determines which command to perform:
- `add`: add a new event
If event with the same name already exists, command is silently discarded
- `name`: unique identifier for a new event
- `delay` _(optional)_: time in seconds until first occurrence of the event, default 0
- `repeat` _(optional)_: time in seconds for periodic repeats or 0 for one-time event, default 0
- `what`: string to be sent when event happens
- `modify`: change an existing event
If event is not found, command is silently discarded
- `name`: identifier of an event to be modified
- `delay` _(optional)_: time in seconds until first occurrence of the event after the modification
- `repeat` _(optional)_: time in seconds for periodic repeats or 0 for one-time event
- `what` _(optional)_: if present, change the string to be sent when event happens
- `cancel`: remove a scheduled event
If event is not found, command is silently discarded
- `name`: identifier of an event to be cancelled