Skip to content

Commit

Permalink
Report compaction errors to user log
Browse files Browse the repository at this point in the history
Change-Id: I2b2c648e716034143a3bf9bf84064a3cadfdec35
Reviewed-on: http://review.couchbase.org/63984
Tested-by: Anders Nygren <anders.nygren@couchbase.com>
Reviewed-by: Aliaksey Artamonau <aliaksiej.artamonau@gmail.com>
  • Loading branch information
Anders Nygren authored and aartamonau committed May 13, 2016
1 parent f066b1a commit ba947af
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions src/compaction_new_daemon.erl
Expand Up @@ -593,14 +593,16 @@ do_chain_compactors(Parent, [Compactor | Compactors]) ->

case Important of
true ->
?log_warning("Compactor for ~p `~s` (pid ~p) terminated "
"unexpectedly: ~p",
[Type, Name, Compactor, Reason]),
ale:warn(?USER_LOGGER,
"Compactor for ~p `~s` (pid ~p) terminated "
"unexpectedly: ~p",
[Type, Name, Compactor, Reason]),
exit(Reason);
false ->
?log_warning("Compactor for ~p `~s` (pid ~p) terminated "
"unexpectedly (ignoring this): ~p",
[Type, Name, Compactor, Reason])
ale:warn(?USER_LOGGER,
"Compactor for ~p `~s` (pid ~p) terminated "
"unexpectedly (ignoring this): ~p",
[Type, Name, Compactor, Reason])
end
end.

Expand Down

0 comments on commit ba947af

Please sign in to comment.