Skip to content

📥 Serverless scheduler-as-a-service ⏰ for ad hoc jobs 📤

Notifications You must be signed in to change notification settings

Cloudbourn/scheduler

Repository files navigation

Serverless scheduler

A completely serverless, high-precision scheduler for ad hoc jobs.

Usage

Send a POST request the to scheduler endpoint with at least the following payload:

{
  "endpoint": "http://example.com/my-webhook",
  "scheduleAt": "2021-08-21T22:00:00.000+0200"
}

The scheduler will make a HTTP request to the defined endpoint soon after the timestamp.

Architecture

Job details are stored in DynamoDB while the scheduling is managed by a combination of Eventbridge schedules and SQS' Message Delays to reach a precision close to 1 second while maintaining a serverless approach that truly scales.

Service diagram

Deploying to AWS

Attention

The scheduler exposes a public API that can be used by anyone. If you intend on deploying this project to production you should add an authorizer of your choice to the API Gateway.

  1. Clone this repo

  2. Copy .example.env to .env. Modify as you see fit.

  3. Search-replace irish-luck in MakeFile with the name of your S3 bucket.

  4.  make deploy

SaaS Alternatives

If you're not comfortable running your own service there are hosted schedulers that will do it for you. 💸

  • Cronhooks - One scheduled hook at a time included in free plan
  • Posthook - 500 free requests per month