anchor.diff:  
       %% If it was in the active view and our connection attempt failed,
       %% remove from the active view altogether.
  -    Active = case is_in_active_view(Peer, Active0) of
  -                 true ->
  -                     remove_from_active_view(Peer, Active0);
  -                 false ->
  -                     Active0
  -             end,
  -
  -    {noreply, State#state{active=Active,
  -                          passive=Passive,
  -                          connections=Connections}};
  +    {Active, RemovedFromActive} =
  +        case is_in_active_view(Peer, Active0) of
  +            true ->
  +                {remove_from_active_view(Peer, Active0), true};
  +            false ->
  +                {Active0, false}
  +        end,
  +
  +    State = case RemovedFromActive of
  +                true ->
  +                    move_random_peer_from_passive_to_active(
  +                        State0#state{active=Active,
  +                                     passive=Passive,
  +                                     connections=Connections});
  +                false ->
  +                    State0#state{active=Active,
  +                                 passive=Passive,
  +                                 connections=Connections}
  +            end,
  +
  +    {noreply, State};
   
   handle_info({connected, Peer, _Tag, _PeerEpoch, _RemoteState}, State) ->
       lager:info("Node ~p is connected", [Peer]),
  
positive.code: handle_info({'EXIT', From, _Reason},
              #state{active=Active0,
                     passive=Passive0,
                     connections=Connections0}=State) ->
      %% Prune active connections from dictionary.
      FoldFun = fun(K, V, {Peer, AccIn}) ->
                        case V =:= From of
  
negative.code: -behaviour(partisan_peer_service_manager).
  
  -define(PASSIVE_VIEW_MAINTENANCE_INTERVAL, 10000).
  -define(RANDOM_PROMOTION_INTERVAL, 5000).
  
  -include("partisan.hrl").
  
  