Skip to content

Commit

Permalink
Merge pull request #223 from pma/pma-ensure_reconnect_if_first_connec…
Browse files Browse the repository at this point in the history
…t_fails

Ensure auto_reconnect if first connect fails

Reviewed-by: russelldb
  • Loading branch information
borshop committed Aug 18, 2015
2 parents 1c75e31 + 2e988fc commit 6e813b7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/riakc_pb_socket.erl
Expand Up @@ -1261,6 +1261,7 @@ init([Address, Port, Options]) ->
{error, Reason} when State#state.auto_reconnect /= true ->
{stop, {tcp, Reason}};
{error, _Reason} ->
erlang:send_after(State#state.reconnect_interval, self(), reconnect),
{ok, State};
Ok ->
Ok
Expand Down

0 comments on commit 6e813b7

Please sign in to comment.