anchor.diff:      to_json_term(?MODULE:get(Key, Time)).
   
   collect_sample() ->
  -    gen_server:call(?MODULE, collect_sample).
  +    gen_server:call(?MODULE, collect_sample, infinity).
   
   
   init(StatDescsFileName) ->
  
positive.code:     
      Rate = list_to_integer(couch_config:get("stats", "rate", "1000")),
      % TODO: Add timer_start to kernel start options.
      timer:apply_interval(Rate, ?MODULE, collect_sample, []).
      
  terminate(_Reason, TRef) ->
      timer:cancel(TRef),
      ok.
  
  handle_call(collect_sample, _, State) ->
      % Gather new stats values to add.
      Incs = lists:map(fun({Key, Value}) ->
          {Key, {incremental, Value}}
  
negative.code:         end,
          ets:insert(?MODULE, {{Key, Rate}, NewAgg})
      end, ets:tab2list(?MODULE)),
      {reply, ok, {TRef, SampleInterval}}.
  
  handle_cast(stop, State) ->
      {stop, normal, State}.
  