%% ============================================================================
-callback init(Options :: term()) ->
- {ConsumptionInterval :: erlang:time(), State :: term()}.
+ {ConsumptionInterval :: non_neg_integer(), State :: term()}.
-callback consume(queue(), State) ->
State.
-record(state,
{ consumer_module :: atom()
, consumer_state :: term()
- , consumption_interval :: erlang:time()
+ , consumption_interval :: non_neg_integer()
, beam_stats_queue :: queue()
}).
_ = self() ! ?SIGNAL_CONSUMPTION,
ok.
--spec schedule_next_consumption(erlang:time()) ->
+-spec schedule_next_consumption(non_neg_integer()) ->
ok.
schedule_next_consumption(Time) ->
_ = erlang:send_after(Time, self(), ?SIGNAL_CONSUMPTION),