Using DynamoDB Streams to Handle Future Scheduled/Delayed/Cron Jobs

Chris Bailey
7 min readFeb 18, 2024

An alternative to cron jobs, “background jobs”, or CloudWatch Events, for tasks that need to be done in the future, on a flexible schedule.

Many software systems need a mechanism to schedule jobs, and “cron” (or CloudWatch Events/Scheduled Jobs in the AWS cloud) or a “delayed job” system are common solutions. However, for a certain class of jobs, there’s an alternative that is quite nice, or certainly better than cron. The alternative is using DynamoDB records with a TTL (time to live) and DynamoDB Streams…

--

--

Chris Bailey

NatureQuant CTO/Co-founder. HotelTonight Co-founder. Cyclist, trail runner, skier, espresso & coffee lover, geek, traveler, foodie.