anchor.diff:                          NewSchedulerInfo = lists:sort(NewSchedulerInfo0),
                           gen_server2:cast(?NODE_MANAGER_NAME, {update_scheduler_info, NewSchedulerInfo}),
   
  -                        ?LOG_MONITORING_STATS("Schedulers advanced info: ~p", [NewSchedulerInfo]),
  +                        log_monitoring_stats("Schedulers advanced info: ~p", [NewSchedulerInfo]),
                           case is_list(SchedulerInfo) of
                               true ->
                                   Percent = lists:map(fun({{I, A0, T0}, {I, A1, T1}}) ->
  
positive.code:             ((MemInt >= MemThreshold) orelse (PNum >= ProcThreshold) orelse (MemUsage >= MemToStartCleaning))) of
          true ->
              spawn(fun() ->
                  ?LOG_MONITORING_STATS("Monitoring state: ~p", [MonState]),
                  ?LOG_MONITORING_STATS("Erlang ets mem usage: ~p", [
                      lists:reverse(lists:sort(lists:map(fun(N) ->
                          {ets:info(N, memory), ets:info(N, size), N} end, ets:all())))
                  ]),
  
negative.code:         _ ->
              LastAnalysisTime
      end.
  
  %%--------------------------------------------------------------------
  %% @private
  %% @doc
  %% Analyse monitoring state and log result.
  %% @end
  %%--------------------------------------------------------------------
  -spec log_monitoring_stats(Format :: io:format(), Args :: [term()]) -> ok.
  log_monitoring_stats(Format, Args) ->
      Now = os:timestamp(),
      {Date, Time} = lager_util:format_time(lager_util:maybe_utc(
          lager_util:localtime_ms(Now))),
      LogFile = application:get_env(?CLUSTER_WORKER_APP_NAME, monitoring_log_file,
          "/tmp/node_manager_monitoring.log"),
      file:write_file(LogFile,
          io_lib:format("~n~s, ~s: " ++ Format, [Date, Time | Args]), [append]),
      ok.
  