server_metrics 0.0.3 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/server_metrics/collectors/cpu.rb +11 -11
- data/lib/server_metrics/collectors/disk.rb +13 -9
- data/lib/server_metrics/collectors/memory.rb +18 -18
- data/lib/server_metrics/collectors/network.rb +4 -4
- data/lib/server_metrics/collectors/processes.rb +27 -23
- data/lib/server_metrics/version.rb +1 -1
- data/test/test_helper.rb +5 -3
- data/test/test_with_fixtures.rb +61 -16
- metadata +116 -116
@@ -25,9 +25,9 @@ class ServerMetrics::Cpu < ServerMetrics::Collector
|
|
25
25
|
uptime_output = `uptime`
|
26
26
|
matches = uptime_output.match(/load averages?: ([\d.]+),? ([\d.]+),? ([\d.]+)\Z/)
|
27
27
|
|
28
|
-
report(
|
29
|
-
|
30
|
-
|
28
|
+
report(:last_minute => matches[1].to_f,
|
29
|
+
:last_five_minutes => matches[2].to_f,
|
30
|
+
:last_fifteen_minutes => matches[3].to_f)
|
31
31
|
end
|
32
32
|
|
33
33
|
# Helper class
|
@@ -102,22 +102,22 @@ class ServerMetrics::Cpu < ServerMetrics::Collector
|
|
102
102
|
divo2 = div / 2
|
103
103
|
|
104
104
|
results = {
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
105
|
+
:user => (100.0 * diff_user + divo2) / div,
|
106
|
+
:system => (100.0 * diff_system + divo2) / div,
|
107
|
+
:idle => (100.0 * diff_idle + divo2) / div,
|
108
|
+
:io_wait => (100.0 * diff_iowait + divo2) / div,
|
109
|
+
:procs_running => self.procs_running,
|
110
|
+
:procs_blocked => self.procs_blocked
|
111
111
|
}
|
112
112
|
|
113
113
|
if diff_steal && steal > 0
|
114
|
-
results[
|
114
|
+
results[:steal] = (100.0 * diff_steal + divo2) / div
|
115
115
|
end
|
116
116
|
|
117
117
|
if self.time && other.time
|
118
118
|
diff_in_seconds = self.time.to_f - other.time.to_f
|
119
119
|
|
120
|
-
results[
|
120
|
+
results[:interrupts] = (self.interrupts.to_f - other.interrupts.to_f) / diff_in_seconds
|
121
121
|
end
|
122
122
|
|
123
123
|
results
|
@@ -33,8 +33,8 @@ class ServerMetrics::Disk < ServerMetrics::MultiCollector
|
|
33
33
|
hash = parsed_lines.select{|l| l["Filesystem"] == device}.first
|
34
34
|
result = {}
|
35
35
|
hash.each_pair do |key,value|
|
36
|
-
|
37
|
-
value = convert_to_mb(value) if [:avail
|
36
|
+
key=normalize_key(key) # downcase, make a symbol, etc
|
37
|
+
value = convert_to_mb(value) if [:avail, :capacity, :size, :used].include?(key)
|
38
38
|
result[key]=value
|
39
39
|
end
|
40
40
|
|
@@ -46,14 +46,14 @@ class ServerMetrics::Disk < ServerMetrics::MultiCollector
|
|
46
46
|
stats = iostat(device)
|
47
47
|
|
48
48
|
if stats
|
49
|
-
counter(device,
|
50
|
-
counter(device,
|
51
|
-
counter(device,
|
52
|
-
counter(device,
|
53
|
-
counter(device,
|
49
|
+
counter(device, :rps, stats['rio'], :per => :second)
|
50
|
+
counter(device, :wps, stats['wio'], :per => :second)
|
51
|
+
counter(device, :rps_kb, stats['rsect'] / 2, :per => :second)
|
52
|
+
counter(device, :wps_kb, stats['wsect'] / 2, :per => :second)
|
53
|
+
counter(device, :utilization, stats['use'] / 10.0, :per => :second)
|
54
54
|
# Not 100% sure that average queue length is present on all distros.
|
55
55
|
if stats['aveq']
|
56
|
-
counter(device,
|
56
|
+
counter(device, :average_queue_length, stats['aveq'], :per => :second)
|
57
57
|
end
|
58
58
|
|
59
59
|
if old = memory(device, "stats")
|
@@ -62,7 +62,7 @@ class ServerMetrics::Disk < ServerMetrics::MultiCollector
|
|
62
62
|
if ios > 0
|
63
63
|
await = ((stats['ruse'] - old['ruse']) + (stats['wuse'] - old['wuse'])) / ios.to_f
|
64
64
|
|
65
|
-
report(device,
|
65
|
+
report(device, :await => await)
|
66
66
|
end
|
67
67
|
end
|
68
68
|
|
@@ -103,4 +103,8 @@ class ServerMetrics::Disk < ServerMetrics::MultiCollector
|
|
103
103
|
return found_device || lvm
|
104
104
|
end
|
105
105
|
|
106
|
+
def normalize_key(key)
|
107
|
+
key = "Used Percent" if /capacity|use.*%|%.*use/i === key
|
108
|
+
key.downcase.gsub(" ", "_").to_sym
|
109
|
+
end
|
106
110
|
end
|
@@ -49,15 +49,15 @@ class ServerMetrics::Memory < ServerMetrics::Collector
|
|
49
49
|
# will be passed at the end to report to Scout
|
50
50
|
report_data = Hash.new
|
51
51
|
|
52
|
-
report_data[
|
53
|
-
report_data[
|
54
|
-
report_data[
|
55
|
-
report_data[
|
52
|
+
report_data[:size] = mem_total
|
53
|
+
report_data[:used] = mem_used
|
54
|
+
report_data[:avail] = mem_total - mem_used
|
55
|
+
report_data[:used_percent] = mem_percent_used
|
56
56
|
|
57
|
-
report_data[
|
58
|
-
report_data[
|
57
|
+
report_data[:swap_size] = swap_total
|
58
|
+
report_data[:swap_used] = swap_used
|
59
59
|
unless swap_total == 0
|
60
|
-
report_data[
|
60
|
+
report_data[:swap_used_percent] = swap_percent_used
|
61
61
|
end
|
62
62
|
@data = report_data
|
63
63
|
|
@@ -80,15 +80,15 @@ class ServerMetrics::Memory < ServerMetrics::Collector
|
|
80
80
|
mem.scan(/(\d+|\d+\.\d+)([bkmg])\s+(\w+)/i) do |amount, unit, label|
|
81
81
|
case label
|
82
82
|
when 'used'
|
83
|
-
report_data[
|
83
|
+
report_data[:used] =
|
84
84
|
(amount.to_f * DARWIN_UNITS[unit.downcase]).round
|
85
85
|
when 'free'
|
86
|
-
report_data[
|
86
|
+
report_data[:avail] =
|
87
87
|
(amount.to_f * DARWIN_UNITS[unit.downcase]).round
|
88
88
|
end
|
89
89
|
end
|
90
|
-
report_data[
|
91
|
-
report_data[
|
90
|
+
report_data[:size] = report_data[:used]+report_data[:avail]
|
91
|
+
report_data[:used_percent] = ((report_data[:used].to_f/report_data[:size])*100).to_i
|
92
92
|
@data = report_data
|
93
93
|
end
|
94
94
|
|
@@ -102,23 +102,23 @@ class ServerMetrics::Memory < ServerMetrics::Collector
|
|
102
102
|
prstat =~ /(ZONEID[^\n]*)\n(.*)/
|
103
103
|
values = $2.split(' ')
|
104
104
|
|
105
|
-
report_data[
|
106
|
-
report_data[
|
105
|
+
report_data[:used] = convert_to_mb(values[3])
|
106
|
+
report_data[:swap_used] = convert_to_mb(values[2])
|
107
107
|
|
108
108
|
prtconf = `/usr/sbin/prtconf | grep Memory`
|
109
109
|
|
110
110
|
prtconf =~ /\d+/
|
111
|
-
report_data[
|
112
|
-
report_data[
|
111
|
+
report_data[:size] = $&.to_i
|
112
|
+
report_data[:used_percent] = (report_data[:used] / report_data[:size].to_f * 100).to_i
|
113
113
|
|
114
114
|
swap = `swap -s`
|
115
115
|
swap =~ /\d+[a-zA-Z]\sused/
|
116
116
|
swap_used = convert_to_mb($&)
|
117
117
|
swap =~ /\d+[a-zA-Z]\savailable/
|
118
118
|
swap_available = convert_to_mb($&)
|
119
|
-
report_data[
|
120
|
-
unless report_data[
|
121
|
-
report_data[
|
119
|
+
report_data[:swap_size] = swap_used+swap_available
|
120
|
+
unless report_data[:swap_size] == 0
|
121
|
+
report_data[:swap_used_percent] = (report_data[:swap_used] / report_data[:swap_size].to_f * 100).to_i
|
122
122
|
end
|
123
123
|
|
124
124
|
@data = report_data
|
@@ -16,10 +16,10 @@ class ServerMetrics::Network < ServerMetrics::MultiCollector
|
|
16
16
|
|
17
17
|
bytes_in, packets_in, bytes_out, packets_out = cols.values_at(0, 1, 8, 9).collect { |i| i.to_i }
|
18
18
|
|
19
|
-
counter(iface,
|
20
|
-
counter(iface,
|
21
|
-
counter(iface,
|
22
|
-
counter(iface,
|
19
|
+
counter(iface, :bytes_in, bytes_in.to_f / 1024.0, :per => :second, :round => 2)
|
20
|
+
counter(iface, :packets_in, packets_in.to_f, :per => :second, :round => 2)
|
21
|
+
counter(iface, :bytes_out, bytes_out.to_f / 1024.0, :per => :second, :round => 2)
|
22
|
+
counter(iface, :packets_out, packets_out.to_f, :per => :second, :round => 2)
|
23
23
|
end
|
24
24
|
end
|
25
25
|
end
|
@@ -11,36 +11,40 @@ class ServerMetrics::Processes
|
|
11
11
|
@last_process_list
|
12
12
|
end
|
13
13
|
|
14
|
-
|
15
|
-
#
|
16
|
-
#
|
14
|
+
|
15
|
+
# This is the main method to call. It returns a hash of processes, keyed by the executable name.
|
16
|
+
# Processes are returned either because they are a top 10 CPU consumer, or a top 10 memory consumer.
|
17
17
|
#
|
18
|
-
#
|
19
|
-
#
|
18
|
+
# The exact number or processes returned depends on the overlap between the two lists (cpu and memory consumers).
|
19
|
+
# The list will always be between 10 and 20 items long.
|
20
|
+
|
21
|
+
# {'mysqld' =>
|
20
22
|
# {
|
21
23
|
# :cmd => "mysqld", # the command (without the path of arguments being run)
|
22
24
|
# :count => 1, # the number of these processes (grouped by the above command)
|
23
|
-
# :cpu => 34, # the total CPU
|
24
|
-
# :memory => 2
|
25
|
-
#
|
26
|
-
#
|
27
|
-
#
|
28
|
-
# [
|
25
|
+
# :cpu => 34, # the total CPU usage of the processes
|
26
|
+
# :memory => 2, # the total memory usage of the processes
|
27
|
+
# :cmd_lines => ["cmd args1", "cmd args2"]
|
28
|
+
# },
|
29
|
+
# 'apache' =>
|
29
30
|
# {
|
30
|
-
#
|
31
|
-
#
|
32
|
-
#
|
33
|
-
|
34
|
-
# }, ...
|
35
|
-
# ]
|
36
|
-
# }
|
31
|
+
# ....
|
32
|
+
# }
|
33
|
+
# }
|
34
|
+
|
37
35
|
def run
|
38
36
|
@processes = calculate_processes # returns a hash
|
37
|
+
top_memory = get_top_processes(:memory, 10) # returns an array
|
38
|
+
top_cpu = get_top_processes(:memory, 10) # returns an array
|
39
|
+
|
40
|
+
# combine the two and index by cmd. The indexing process will remove duplicates
|
41
|
+
result = (top_cpu + top_memory).inject(Hash.new) {|temp_hash,process_hash| temp_hash[process_hash[:cmd]] = process_hash; temp_hash }
|
39
42
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
43
|
+
# An alternate approach is to return an array with two separate arrays. More explicit, but more verbose.
|
44
|
+
#{
|
45
|
+
# :top_memory => get_top_processes(:memory, 10),
|
46
|
+
# :top_cpu => get_top_processes(:cpu, 10)
|
47
|
+
#}
|
44
48
|
end
|
45
49
|
|
46
50
|
# called from run(). This method lists all the processes running on the server, groups them by command,
|
@@ -90,7 +94,7 @@ class ServerMetrics::Processes
|
|
90
94
|
# Returns an array of hashes:
|
91
95
|
# [{:cmd=>"ruby", :cpu=>30.0, :memory=>100, :uid=>1,:cmdlines=>[]}, {:cmd => ...} ]
|
92
96
|
def get_top_processes(order_by, num)
|
93
|
-
@processes.map { |key, hash| {:cmd => key}.merge(hash) }.sort { |a, b| a[order_by] <=> b[order_by] }.reverse[0...num
|
97
|
+
@processes.map { |key, hash| {:cmd => key}.merge(hash) }.sort { |a, b| a[order_by] <=> b[order_by] }.reverse[0...num]
|
94
98
|
end
|
95
99
|
|
96
100
|
# for persisting to a file -- conforms to same basic API as the Collectors do.
|
data/test/test_helper.rb
CHANGED
@@ -1,10 +1,12 @@
|
|
1
1
|
$LOAD_PATH << File.expand_path( File.dirname(__FILE__) + '/..' )
|
2
2
|
require 'test/unit'
|
3
|
-
require '
|
3
|
+
require 'rubygems'
|
4
4
|
require 'pry'
|
5
5
|
require 'awesome_print'
|
6
6
|
require 'timecop'
|
7
|
-
require 'mocha'
|
7
|
+
require 'mocha/setup'
|
8
|
+
|
9
|
+
require 'lib/server_metrics'
|
8
10
|
AwesomePrint.defaults = {
|
9
11
|
:indent => -2,
|
10
12
|
:sort_keys =>true
|
@@ -46,4 +48,4 @@ class FixtureFile
|
|
46
48
|
@sections[key]
|
47
49
|
end
|
48
50
|
end
|
49
|
-
end
|
51
|
+
end
|
data/test/test_with_fixtures.rb
CHANGED
@@ -10,9 +10,9 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
10
10
|
c.expects(:`).with("uptime").returns(fixture.command("uptime")).once
|
11
11
|
|
12
12
|
c.run
|
13
|
-
assert c.data[
|
14
|
-
assert c.data[
|
15
|
-
assert c.data[
|
13
|
+
assert c.data[:last_minute]
|
14
|
+
assert c.data[:last_five_minutes]
|
15
|
+
assert c.data[:last_fifteen_minutes]
|
16
16
|
assert_equal 3, c.data.keys.size
|
17
17
|
c
|
18
18
|
end
|
@@ -28,8 +28,8 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
28
28
|
c.run
|
29
29
|
end
|
30
30
|
|
31
|
-
assert c.data[
|
32
|
-
assert c.data[
|
31
|
+
assert c.data[:io_wait]
|
32
|
+
assert c.data[:idle]
|
33
33
|
end
|
34
34
|
|
35
35
|
|
@@ -43,18 +43,54 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
43
43
|
c.run
|
44
44
|
|
45
45
|
assert_equal ["/dev/xvda1"], c.data.keys
|
46
|
+
|
46
47
|
res = c.data["/dev/xvda1"]
|
47
48
|
|
48
|
-
assert res[
|
49
|
-
assert res[
|
50
|
-
assert res[
|
51
|
-
assert res[
|
52
|
-
assert res[
|
53
|
-
assert res[
|
49
|
+
assert res[:avail]
|
50
|
+
assert res[:filesystem]
|
51
|
+
assert res[:mounted_on]
|
52
|
+
assert res[:size]
|
53
|
+
assert res[:used_percent]
|
54
|
+
assert res[:used]
|
54
55
|
assert_equal 6, res.keys.size
|
55
56
|
c
|
56
57
|
end
|
57
58
|
|
59
|
+
def test_disk_converts_use_percent_and_capacity_to_used_percent
|
60
|
+
response_varieties = []
|
61
|
+
response_varieties << <<-eos
|
62
|
+
Filesystem Capacity
|
63
|
+
/dev/xvda1 70%
|
64
|
+
none 0%
|
65
|
+
none 0%
|
66
|
+
eos
|
67
|
+
|
68
|
+
response_varieties << <<-eos
|
69
|
+
Filesystem Use%
|
70
|
+
/dev/xvda1 70%
|
71
|
+
none 0%
|
72
|
+
none 0%
|
73
|
+
eos
|
74
|
+
|
75
|
+
response_varieties<< <<-eos
|
76
|
+
Filesystem %Use
|
77
|
+
/dev/xvda1 70%
|
78
|
+
none 0%
|
79
|
+
none 0%
|
80
|
+
eos
|
81
|
+
|
82
|
+
fixture = fixtures(:disk)
|
83
|
+
response_varieties.each do |response|
|
84
|
+
c = ServerMetrics::Disk.new()
|
85
|
+
c.expects(:`).with("mount").returns(fixture.command("mount")).once
|
86
|
+
c.expects(:`).with("cat /proc/diskstats").returns(fixture.command("cat /proc/diskstats")).once
|
87
|
+
c.expects(:`).with("df -h").returns(response)
|
88
|
+
c.run
|
89
|
+
|
90
|
+
assert c.data['/dev/xvda1'][:used_percent]
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
58
94
|
# Second run we also get counter data
|
59
95
|
def test_disk_second_run
|
60
96
|
c=test_disk
|
@@ -69,8 +105,10 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
69
105
|
|
70
106
|
assert_equal ["/dev/xvda1"], c.data.keys
|
71
107
|
res = c.data["/dev/xvda1"]
|
72
|
-
assert res[
|
73
|
-
assert res[
|
108
|
+
assert res[:wps]
|
109
|
+
assert res[:rps]
|
110
|
+
assert res[:rps_kb]
|
111
|
+
assert res[:wps_kb]
|
74
112
|
end
|
75
113
|
|
76
114
|
def test_memory
|
@@ -80,7 +118,14 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
80
118
|
c.expects(:`).with("cat /proc/meminfo").returns(fixture.command("cat /proc/meminfo")).once
|
81
119
|
c.run
|
82
120
|
assert_equal 7, c.data.keys.size
|
83
|
-
|
121
|
+
# the field names should align with the disk field names
|
122
|
+
assert c.data[:swap_size]
|
123
|
+
assert c.data[:swap_used]
|
124
|
+
assert c.data[:swap_used_percent]
|
125
|
+
assert c.data[:used]
|
126
|
+
assert c.data[:avail]
|
127
|
+
assert c.data[:used_percent]
|
128
|
+
assert c.data[:size]
|
84
129
|
end
|
85
130
|
|
86
131
|
def test_network
|
@@ -98,8 +143,8 @@ class TestWithFixtures < Test::Unit::TestCase
|
|
98
143
|
assert c.data.keys.include?("eth1")
|
99
144
|
assert_equal 2, c.data.keys.size
|
100
145
|
|
101
|
-
assert c.data["eth0"][
|
102
|
-
assert c.data["eth1"][
|
146
|
+
assert c.data["eth0"][:bytes_in]
|
147
|
+
assert c.data["eth1"][:bytes_in]
|
103
148
|
end
|
104
149
|
end
|
105
150
|
|
metadata
CHANGED
@@ -1,132 +1,135 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: server_metrics
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.5
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 0
|
9
|
-
- 3
|
10
|
-
version: 0.0.3
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Andre Lewis
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
dependencies:
|
21
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2013-10-30 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
22
15
|
name: sys-proctable
|
23
|
-
|
24
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
25
17
|
none: false
|
26
|
-
requirements:
|
27
|
-
- -
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
|
30
|
-
segments:
|
31
|
-
- 0
|
32
|
-
version: "0"
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0'
|
33
22
|
type: :runtime
|
34
|
-
version_requirements: *id001
|
35
|
-
- !ruby/object:Gem::Dependency
|
36
|
-
name: bundler
|
37
23
|
prerelease: false
|
38
|
-
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0'
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: bundler
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
39
33
|
none: false
|
40
|
-
requirements:
|
34
|
+
requirements:
|
41
35
|
- - ~>
|
42
|
-
- !ruby/object:Gem::Version
|
43
|
-
|
44
|
-
segments:
|
45
|
-
- 1
|
46
|
-
- 3
|
47
|
-
version: "1.3"
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '1.3'
|
48
38
|
type: :development
|
49
|
-
version_requirements: *id002
|
50
|
-
- !ruby/object:Gem::Dependency
|
51
|
-
name: rake
|
52
39
|
prerelease: false
|
53
|
-
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
54
41
|
none: false
|
55
|
-
requirements:
|
56
|
-
- -
|
57
|
-
- !ruby/object:Gem::Version
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
42
|
+
requirements:
|
43
|
+
- - ~>
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '1.3'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: rake
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
62
54
|
type: :development
|
63
|
-
version_requirements: *id003
|
64
|
-
- !ruby/object:Gem::Dependency
|
65
|
-
name: awesome_print
|
66
55
|
prerelease: false
|
67
|
-
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: awesome_print
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
68
65
|
none: false
|
69
|
-
requirements:
|
70
|
-
- -
|
71
|
-
- !ruby/object:Gem::Version
|
72
|
-
|
73
|
-
segments:
|
74
|
-
- 0
|
75
|
-
version: "0"
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '0'
|
76
70
|
type: :development
|
77
|
-
version_requirements: *id004
|
78
|
-
- !ruby/object:Gem::Dependency
|
79
|
-
name: pry
|
80
71
|
prerelease: false
|
81
|
-
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
|
+
name: pry
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
82
81
|
none: false
|
83
|
-
requirements:
|
84
|
-
- -
|
85
|
-
- !ruby/object:Gem::Version
|
86
|
-
|
87
|
-
segments:
|
88
|
-
- 0
|
89
|
-
version: "0"
|
82
|
+
requirements:
|
83
|
+
- - ! '>='
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '0'
|
90
86
|
type: :development
|
91
|
-
version_requirements: *id005
|
92
|
-
- !ruby/object:Gem::Dependency
|
93
|
-
name: timecop
|
94
87
|
prerelease: false
|
95
|
-
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ! '>='
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: timecop
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
96
97
|
none: false
|
97
|
-
requirements:
|
98
|
-
- -
|
99
|
-
- !ruby/object:Gem::Version
|
100
|
-
|
101
|
-
segments:
|
102
|
-
- 0
|
103
|
-
version: "0"
|
98
|
+
requirements:
|
99
|
+
- - ! '>='
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: '0'
|
104
102
|
type: :development
|
105
|
-
version_requirements: *id006
|
106
|
-
- !ruby/object:Gem::Dependency
|
107
|
-
name: mocha
|
108
103
|
prerelease: false
|
109
|
-
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ! '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '0'
|
110
|
+
- !ruby/object:Gem::Dependency
|
111
|
+
name: mocha
|
112
|
+
requirement: !ruby/object:Gem::Requirement
|
110
113
|
none: false
|
111
|
-
requirements:
|
112
|
-
- -
|
113
|
-
- !ruby/object:Gem::Version
|
114
|
-
|
115
|
-
segments:
|
116
|
-
- 0
|
117
|
-
version: "0"
|
114
|
+
requirements:
|
115
|
+
- - ! '>='
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
118
|
type: :development
|
119
|
-
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
none: false
|
122
|
+
requirements:
|
123
|
+
- - ! '>='
|
124
|
+
- !ruby/object:Gem::Version
|
125
|
+
version: '0'
|
120
126
|
description: Collect information about disks, memory, CPU, etc
|
121
|
-
email:
|
127
|
+
email:
|
122
128
|
- andre@scoutapp.com
|
123
129
|
executables: []
|
124
|
-
|
125
130
|
extensions: []
|
126
|
-
|
127
131
|
extra_rdoc_files: []
|
128
|
-
|
129
|
-
files:
|
132
|
+
files:
|
130
133
|
- .gitignore
|
131
134
|
- Gemfile
|
132
135
|
- LICENSE.txt
|
@@ -153,41 +156,38 @@ files:
|
|
153
156
|
- test/test_basics.rb
|
154
157
|
- test/test_helper.rb
|
155
158
|
- test/test_with_fixtures.rb
|
156
|
-
has_rdoc: true
|
157
159
|
homepage: http://scoutapp.com
|
158
|
-
licenses:
|
160
|
+
licenses:
|
159
161
|
- MIT
|
160
162
|
post_install_message:
|
161
163
|
rdoc_options: []
|
162
|
-
|
163
|
-
require_paths:
|
164
|
+
require_paths:
|
164
165
|
- lib
|
165
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
166
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
166
167
|
none: false
|
167
|
-
requirements:
|
168
|
-
- -
|
169
|
-
- !ruby/object:Gem::Version
|
170
|
-
|
171
|
-
segments:
|
168
|
+
requirements:
|
169
|
+
- - ! '>='
|
170
|
+
- !ruby/object:Gem::Version
|
171
|
+
version: '0'
|
172
|
+
segments:
|
172
173
|
- 0
|
173
|
-
|
174
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
174
|
+
hash: 3269620975841777684
|
175
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
175
176
|
none: false
|
176
|
-
requirements:
|
177
|
-
- -
|
178
|
-
- !ruby/object:Gem::Version
|
179
|
-
|
180
|
-
segments:
|
177
|
+
requirements:
|
178
|
+
- - ! '>='
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: '0'
|
181
|
+
segments:
|
181
182
|
- 0
|
182
|
-
|
183
|
+
hash: 3269620975841777684
|
183
184
|
requirements: []
|
184
|
-
|
185
185
|
rubyforge_project:
|
186
|
-
rubygems_version: 1.
|
186
|
+
rubygems_version: 1.8.25
|
187
187
|
signing_key:
|
188
188
|
specification_version: 3
|
189
189
|
summary: For use with the Scout agent
|
190
|
-
test_files:
|
190
|
+
test_files:
|
191
191
|
- test/fixtures/cpu.txt
|
192
192
|
- test/fixtures/disk.txt
|
193
193
|
- test/fixtures/memory.txt
|