Sha256: 8891edd7d8bddd356f485c15f0c743c5af8e9fba19a82c5cdd09c2a7a3c6ebd5

Contents?: true

Size: 529 Bytes

Versions: 5

Compression:

Stored size: 529 Bytes

Contents

#!/usr/bin/env escript
-export([main/1]).
main(_Any) ->
  gruff:start(),
  MemoryWriter = stat_writer:start(<<"Memory Info">>, fun() -> erlang:memory() end),
  ProcessWriter = stat_writer:start(<<"Process Info">>, 
    fun() -> 
      {_, QueueLength} = erlang:process_info(erlang:whereis(gruff), message_queue_len),
      [{processes, erlang:system_info(process_count)},
       {gruff_queue_length, QueueLength}] 
    end
  ),
  receive
  after 20000 ->
    MemoryWriter ! stop,
    ProcessWriter ! stop,
    elang:halt()
  end.

Version data entries

5 entries across 5 versions & 3 rubygems

Version Path
mojombo-erlectricity-0.2.1 examples/gruff/stat_run.erl
tmm1-erlectricity-0.2.1 examples/gruff/stat_run.erl
erlectricity-0.2.0 examples/gruff/stat_run.erl
erlectricity-0.1.0 examples/gruff/stat_run.erl
erlectricity-0.2.1 examples/gruff/stat_run.erl