Sha256: 426bf7b45061f4d2069c80307a0b3b2532f3801f56f5f9d5aba9170c58f1f734
Contents?: true
Size: 718 Bytes
Versions: 1
Compression:
Stored size: 718 Bytes
Contents
require "vmstat" module AppPerfAgent module Plugin module System class Network < AppPerfAgent::Plugin::Base def call inets = Vmstat.ethernet_devices inets.flat_map {|inet| [ [ AppPerfAgent::Types::NETWORK, "system.network.in_bytes", inet.name.to_s, inet.in_bytes ], [ AppPerfAgent::Types::NETWORK, "system.network.out_bytes", inet.name.to_s, inet.out_bytes ] ] } end end end end end AppPerfAgent.logger.info "Loading Network monitoring."
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
app_perf_agent-0.0.2 | lib/app_perf_agent/plugin/system/network.rb |