anchor.diff:           async_insert_object/3,
            stop/1,
            clear/1,
  +         expire/1,
            destroy/1]).
   
   -export([poke/1,
  
positive.code: 
  -spec do_poke(state()) -> state().
  do_poke(State) ->
      State1 = maybe_clear(State),
      State2 = maybe_build(State1),
      State2.
  
  %% If past expiration, clear all hashtrees.
  -spec maybe_clear(state()) -> state().
  maybe_clear(State=#state{lock=undefined, built=true}) ->
      Diff = timer:now_diff(os:timestamp(), State#state.build_time),
      Expire = app_helper:get_env(riak_kv,
                                  anti_entropy_expire,
  
negative.code:     hashtree:write_meta(<<"built">>, <<1>>, Tree0),
      hashtree:write_meta(<<"build_time">>, term_to_binary(BuildTime), Tree0),
      riak_kv_entropy_info:tree_built(Index, BuildTime),
      State#state{built=true, build_time=BuildTime, expired=false}.
  
  %% Determine the build time for all trees associated with this
  %% index. The build time is stored as metadata in the on-disk file. If
  