Cron Jobs on Multiple Replicas: Running Scheduled Tasks Safely
Why in-process cron fires once per replica, how locks, leader election and platform schedulers coordinate, and how to make jobs safe to run twice.
17 min read
Tag
Why in-process cron fires once per replica, how locks, leader election and platform schedulers coordinate, and how to make jobs safe to run twice.
17 min read
Stop duplicate cron runs when your monolith scales out: compare advisory locks, lease tables and leader election, and build idempotent, observable jobs.
20 min read
How postgres advisory locks work, how to use them for singleton jobs and leader election across replicas, and the session and pooling pitfalls to design around.
15 min read