Packages

A cron like system built in Elixir, that you can mount in your supervision tree

Current section

Files

Jump to
cronex lib cronex.ex
Raw

lib/cronex.ex

defmodule Cronex do
use Application
def start(_type, _args) do
import Supervisor.Spec, warn: false
children = [
supervisor(Cronex.Table, [nil, [name: :cronex_table]]),
supervisor(Task.Supervisor, [[name: :cronex_job_supervisor]])
]
opts = [strategy: :one_for_one, name: Cronex.Supervisor]
Supervisor.start_link(children, opts)
end
end