Skip to content

Commit

Permalink
Clear existing streams from upr client if updater crash
Browse files Browse the repository at this point in the history
If updater crash due to some reason, the next updater run
should not be affected. If updater crashes while reading from
a upr stream, the upr stream request will be active within the
upr client. We need to remove the active stream if updater exits
with an error.

Change-Id: I36ee7bf3ef7673cab2547762db7e3db5ae18c355
Reviewed-on: http://review.couchbase.org/38480
Reviewed-by: Volker Mische <volker.mische@gmail.com>
Tested-by: Sarath Lakshman <sarath@couchbase.com>
  • Loading branch information
t3rm1n4l committed Jun 19, 2014
1 parent 98d55e0 commit f51f15a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/couch_set_view/src/couch_set_view_group.erl
Expand Up @@ -1249,6 +1249,7 @@ handle_info({'EXIT', Pid, {updater_error, Error}}, #state{updater_pid = Pid, gro
updater_state = not_running,
update_listeners = Listeners2
},
stop_upr_streams(State),
?inc_updater_errors(State2#state.group),
case State#state.shutdown of
true ->
Expand Down

0 comments on commit f51f15a

Please sign in to comment.