Skip to content

Commit

Permalink
Support Consul 1.11 responses
Browse files Browse the repository at this point in the history
as suggested by @maestroes.

Closes #4149.
  • Loading branch information
michaelklishin committed Feb 25, 2022
1 parent c068706 commit 6f59f7b
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -498,6 +498,15 @@ send_health_check_pass() ->
"Consul responded to a health check with 429 Too Many Requests",
#{domain => ?RMQLOG_DOMAIN_PEER_DIS}),
ok;
%% starting with Consul 1.11, see https://github.com/hashicorp/consul/pull/11950
{error, "404"} ->
?LOG_WARNING(
"Consul responded to a health check with a 404 status, will "
"wait and try re-registering",
#{domain => ?RMQLOG_DOMAIN_PEER_DIS}),
maybe_re_register(wait_for_list_nodes()),
ok;
%% prior to Consul 1.11, see https://github.com/hashicorp/consul/pull/11950
{error, "500"} ->
?LOG_WARNING(
"Consul responded to a health check with a 500 status, will "
Expand Down

0 comments on commit 6f59f7b

Please sign in to comment.