Code Monkey home page Code Monkey logo

beam_stats's Introduction

migrated: https://gitlab.com/l1905/maven-business/lookio-legacy/beam_stats

Build Status

beam_stats

Periodically collects and pushes VM metrics to arbitrary consumer processes, which, in-turn, can do whatever they want with the given data (such as serialize and forward to some time series storage). Includes, off by default, example implementations of consumers for:

  • StatsD (beam_stats_consumer_statsd)
  • Graphite (beam_stats_consumer_graphite)
  • CSV file (beam_stats_consumer_csv)

Essentially like folsomite, but different. Different in the following ways:

  • More-general: consumers other than graphite can be defined
  • More-focused: only concerned with VM metrics, while folsomite ships off everything from folsom (in addition to VM metrics)
  • Easier-(for me!)-to-reason-about implementation:
    • Well-defined metrics-to-binary conversions, as opposed to the nearly-arbitrary term-to-string conversions used in folsomite
    • Spec'd, tested and Dialyzed

Adding consumers

At app config time

{env,
  [ {production_interval , 30000}
  , {consumers,
      [ {beam_stats_consumer_statsd,
          [ {consumption_interval , 60000}
          , {dst_host             , "localhost"}
          , {dst_port             , 8125}
          , {src_port             , 8124}
          , {num_msgs_per_packet  , 10}

          % If you want to name your node something other than what
          % erlang:node() returns:
          , {static_node_name     , <<"unicorn_at_rainbow">>}
          ]}
      , {beam_stats_consumer_graphite,
          [ {consumption_interval , 60000}
          , {host                 , "localhost"}
          , {port                 , 2003}
          , {timeout              , 5000}
          ]}
      , {beam_stats_consumer_csv,
          [ {consumption_interval , 60000}
          , {path                 , "beam_stats.csv"}
          ]}
      , {some_custom_consumer_module,
          [ {some_custom_option_a, "abc"}
          , {some_custom_option_b, 123}
          ]}

      ]}
  ]}

Dynamically

beam_stats_consumer:add(consumer_module, ConsumerOptions).

Removing consumers

Not yet implemented.

beam_stats's People

Contributors

xandkar avatar puzza007 avatar scottwestover avatar

Watchers

James Cloos avatar Dmitriy Ivolgin avatar  avatar Andrew Ramirez avatar  avatar Omer Berger avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.