anchor.diff:      {noreply, State#st{pid=undefined}};
   handle_info({'EXIT', _, {reset, Pid}}, #st{idx=Idx, pid=Pid}=State) ->
       {ok, NewIdxState} = gen_server:call(State#st.idx, reset),
  -    Pid2 = spawn_link(fun() -> update(Idx, State#st.mod, NewIdxState) end),
  +    Pid2 = spawn_link(?MODULE, update, [Idx, State#st.mod, NewIdxState]),
       {noreply, State#st{pid=Pid2}};
   handle_info({'EXIT', Pid, normal}, #st{pid=Pid}=State) ->
       {noreply, State#st{pid=undefined}};
  
positive.code: handle_call({update, IdxState}, _From, #st{idx=Idx, mod=Mod}=State) ->
      Args = [Mod:get(db_name, IdxState), Mod:get(idx_name, IdxState)],
      ?LOG_INFO("Starting index update for db: ~s idx: ~s", Args),
      Pid = spawn_link(fun() -> update(Idx, Mod, IdxState) end),
      {reply, ok, State#st{pid=Pid}};
  handle_call({restart, IdxState}, _From, #st{idx=Idx, mod=Mod}=State) ->
      Args = [Mod:get(db_name, IdxState), Mod:get(idx_name, IdxState)],
  
negative.code: %% API
  -export([start_link/2, run/2, is_running/1, update/2, restart/2]).
  
  %% for upgrades
  -export([update/3]).
  
  %% gen_server callbacks
  -export([init/1, terminate/2, code_change/3]).
  -export([handle_call/3, handle_cast/2, handle_info/2]).
  