Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Job Schedulers - BLR Clojure Meetup (Dec 7/2019)

Job Schedulers - BLR Clojure Meetup (Dec 7/2019)

Atif Haider

December 07, 2019
Tweet

More Decks by Atif Haider

Other Decks in Programming

Transcript

  1. About me • Worked as engineer, architect, founder in the

    last 11 years • Built systems using Common Lisp, Python, Scala and Clojure • Former Founder of AirCTO which got acquired by Gojek in April 2019 • Currently heading Tech recruitment innovation at Gojek
  2. What is job scheduling and why do we need them?

    As we all know, job Schedulers are designed to carry out repetitive tasks as defined in a schedule based upon calendar and event conditions. For use cases like: • Send emails to customers about new offers every wednesday at 12:30 AM • Update certain data into DB by calling some third party API every day • Send out transaction reports to managers every week • And many more..
  3. Scheduling options in different languages • Tickers, GoCron in Go

    • Crono, whenever in Ruby (even Sidekiq allows you to do that) • Celery Beat, Timeloop in Python
  4. Scheduling options in Clojure There are many and most of

    them are outdated or half-baked. For instance: • Monotony • Chime • Tea-time • Cronj • At-at • And half a dozen more.
  5. Scheduling options in Clojure And at some point of time

    we feel lost? One of libraries that often pops-up for your search is Quartzite but looks like outdated (last commit: 2 years ago) Quartzite is based on the Quartz Scheduler, one of the most powerful and feature rich open source scheduling tools. And it is stable.
  6. Setting up one time and periodic scheduler Download from Clojars:

    [clojurewerkz/quartzite "2.1.0"] • Define a job • Define triggers and schedules • Initialize scheduler Let’s dig into the code!
  7. Setting up periodic persistent scheduler DB schema emafor Quartz Default

    Quartz properties Let’s dig into the code> https://github.com/atifh/clj-scheduler/