Skip to content

Commit 7db6b95

Browse files
BashoBasho
authored andcommitted
fix heartbeat bug by adding new pattern match and debug line
1 parent 0489c7c commit 7db6b95

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/riak_repl2_rtsource_conn.erl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -480,6 +480,11 @@ schedule_heartbeat(State = #state{hb_interval_tref = undefined,
480480
TRef = erlang:send_after(timer:seconds(HBInterval), self(), send_heartbeat),
481481
State#state{hb_interval_tref = TRef};
482482

483+
schedule_heartbeat(State = #state{hb_interval_tref = _TRef,
484+
hb_interval = HBInterval}) when is_integer(HBInterval) ->
485+
lager:debug("hb_interval_tref is not undefined when attempting to schedule new heartbeat."),
486+
State;
487+
483488
schedule_heartbeat(State) ->
484489
lager:warning("Heartbeat is misconfigured and is not a valid integer."),
485490
State.

0 commit comments

Comments
 (0)