Changeset View
Changeset View
Standalone View
Standalone View
lib/kolab_wopi.ex
defmodule KolabWopi do | defmodule KolabWopi do | ||||
use Application | use Application | ||||
# See http://elixir-lang.org/docs/stable/elixir/Application.html | # See http://elixir-lang.org/docs/stable/elixir/Application.html | ||||
# for more information on OTP Applications | # for more information on OTP Applications | ||||
def start(_type, _args) do | def start(_type, _args) do | ||||
import Supervisor.Spec, warn: false | import Supervisor.Spec, warn: false | ||||
children = [ | children = [ | ||||
# Define workers and child supervisors to be supervised | # Define workers and child supervisors to be supervised | ||||
worker(__MODULE__.API, []), | worker(__MODULE__.API, []) | ||||
worker(__MODULE__.Chwala, []) | |||||
] | ] | ||||
# See http://elixir-lang.org/docs/stable/elixir/Supervisor.html | # See http://elixir-lang.org/docs/stable/elixir/Supervisor.html | ||||
# for other strategies and supported options | # for other strategies and supported options | ||||
opts = [strategy: :one_for_one, name: __MODULE__.Supervisor] | opts = [strategy: :one_for_one, name: __MODULE__.Supervisor] | ||||
Supervisor.start_link(children, opts) | Supervisor.start_link(children, opts) | ||||
end | end | ||||
end | end |