anchor.diff:  init({Mod, IdxState}) ->
       ok = config:listen_for_changes(?MODULE, nil),
       DbName = Mod:get(db_name, IdxState),
  +    erlang:send_after(?CHECK_INTERVAL, self(), maybe_close),
       Resp = couch_util:with_db(DbName, fun(Db) ->
           case Mod:open(Db, IdxState) of
               {ok, IdxSt} ->
  
positive.code:             erlang:send_after(Delay, self(), commit),
              {noreply, State}
      end;
  handle_info({'DOWN', _, _, _Pid, _}, #st{mod=Mod, idx_state=IdxState}=State) ->
      Args = [Mod:get(db_name, IdxState), Mod:get(idx_name, IdxState)],
      ?LOG_INFO("Index shutdown by monitor notice for db: ~s idx: ~s", Args),
  
negative.code: -include_lib("couch/include/couch_db.hrl").
  
  
  -define(CHECK_INTERVAL, 600000). % 10 minutes
  
  
  -record(st, {
      mod,
      idx_state,
  