anchor.diff:  
   process_statistics(
       ReplyFun,
  -    #{process_statistics := #{last := Last, value := Stats}}
  +    #{process_statistics := #{last := Last, value := Stats}} = State
   ) ->
       Now = os:timestamp(),
       case timer:now_diff(Now, Last) of
           Diff when Diff > ?CACHE_STALE_AFTER ->
               NewStats = get_process_stats(),
               ReplyFun(NewStats),
  -            #{process_statistics => #{last => Now, value => NewStats}};
  +            State#{process_statistics => #{last => Now, value => NewStats}};
           _ ->
               ReplyFun(Stats),
  -            #{process_statistics => #{last => Last, value => Stats}}
  +            State
       end;
  -process_statistics(ReplyFun, _) ->
  +process_statistics(ReplyFun, State) ->
       NewStats = get_process_stats(),
       ReplyFun(NewStats),
  -    #{process_statistics => #{last => os:timestamp(), value => NewStats}}.
  +    State#{process_statistics => #{last => os:timestamp(), value => NewStats}}.
   
   get_process_stats() ->
       ProcessInfoMaps = [
  
positive.code: request_metric(_) -> noreply.
  
  %% imem_gen_metrics callback
  init() -> {ok, undefined}.
  
  handle_metric_req(system_information, ReplyFun, State) ->
      {_, FreeMemory, TotalMemory} = imem:get_os_memory(),
  
negative.code: process_info_max([PiMap | ProcessInfoMaps], Stat) ->
      process_info_max(ProcessInfoMaps, process_max(PiMap, Stat)).
  
  process_max({Process, ProcessInfo}, Stats) ->
      maps:fold(
          fun(Key, Val, Max) ->
              MaxKey = max_key(Key),
              case Max of
                  #{MaxKey := #{value := OldVal}} when Val > OldVal ->
                       Max#{MaxKey => #{value => Val, process => Process}};
                  _ -> Max#{MaxKey => #{value => Val, process => Process}}
              end
          end, Stats, ProcessInfo
      ).
  
  max_key(heap_size) -> max_heap_size;
  max_key(stack_size) -> max_stack_size;
  max_key(total_heap_size) -> max_total_heap_size;
  max_key(message_queue_len) -> max_message_queue_len.