anchor.diff:      end,
       {reply, Reply, State};
   
  -handle_call(_, _, State) ->
  +handle_call(update, _, State) ->
  +    %% Run a persistence operation on all torrents
  +    %% TODO - in the ETS implementation the state of all inactive
  +    %%        torrents was flushed out on each persitance operation.
  +    _ = [begin
  +        TorentID = proplists:get_value(id, Props)
  +        Filename = proplists:get_value(filename, Props),
  +        track_torrent(TorrentID, Filename)
  +    end || Props <- etorrent_table:all_torrents()],
  +    ok.
  +
       {reply, ok, State}.
   
   handle_cast(_, State) ->
  
positive.code: -export([start_link/0,
           query_state/1]).
  
  %% gen_server callbacks
  -export([init/1,
           handle_call/3,
  
negative.code: %% @end
  -spec query_state(integer()) -> unknown | {value, [{term(), term()}]}.
  query_state(Id) ->
      gen_server:call(?SERVER, {query_state, Id}).
  
  -spec srv_name() -> atom().
  srv_name() ->
      ?MODULE.
  
  %% @doc
  %% Create a snapshot of all torrents that are loaded into etorrent
  %% at the time when this function is called.
  %% @end
  -spec update() -> ok.
  update() ->
      gen_server:call(srv_name(), update).
  
  %% ==================================================================
  
  upgrade(1, St) ->
      upgrade1(St).
  