summaryrefslogtreecommitdiff
path: root/src/rabbit.erl
diff options
context:
space:
mode:
authorMichael Klishin <michael@clojurewerkz.org>2017-10-19 20:04:23 +0300
committerMichael Klishin <michael@clojurewerkz.org>2017-10-19 20:04:23 +0300
commit51aca8851eba66445ad5b164fc92b2ffa0692fc2 (patch)
treebb2ddc043bfea9756ea847ef88efe896ecd1d990 /src/rabbit.erl
parentbe796e0c6fe9237ab5e9b1bae86b0de2f7b0a19a (diff)
downloadrabbitmq-server-git-51aca8851eba66445ad5b164fc92b2ffa0692fc2.tar.gz
Use a special exit code when server reports an error on shutdown
This way tools that manage RabbitMQ nodes can detect this condition among a bunch of fairly generic exit codes. Note that when a timeout occurs, we still use a "temporary failure" code. See rabbitmq/rabbitmq-server#1396 for context.
Diffstat (limited to 'src/rabbit.erl')
-rw-r--r--src/rabbit.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rabbit.erl b/src/rabbit.erl
index 033379bad1..4a9ae6ba76 100644
--- a/src/rabbit.erl
+++ b/src/rabbit.erl
@@ -453,7 +453,7 @@ stop_and_halt() ->
stop()
catch Type:Reason ->
rabbit_log:error("Error trying to stop RabbitMQ: ~p:~p", [Type, Reason]),
- error({Type, Reason})
+ erlang:error({Type, Reason})
after
%% Enclose all the logging in the try block.
%% init:stop() will be called regardless of any errors.