Skip to content

Commit

Permalink
Start traces after extra sinks are started
Browse files Browse the repository at this point in the history
Previously, if you configured a trace to use an
extra sink, you'd get a noproc error. Addresses
issue erlang-lager#296 on github.
  • Loading branch information
jadeallenx committed Dec 17, 2015
1 parent 7177cb0 commit 66869e2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lager_app.erl
Expand Up @@ -208,7 +208,6 @@ start(_StartType, _StartArgs) ->
start_handlers(?DEFAULT_SINK,
get_env(lager, handlers, ?DEFAULT_HANDLER_CONF)),

ok = add_configured_traces(),

lager:update_loglevel_config(?DEFAULT_SINK),

Expand All @@ -223,6 +222,8 @@ start(_StartType, _StartArgs) ->
%% Now handle extra sinks
configure_extra_sinks(get_env(lager, extra_sinks, [])),

ok = add_configured_traces(),

clean_up_config_checks(),

{ok, Pid, SavedHandlers}.
Expand Down

0 comments on commit 66869e2

Please sign in to comment.