stat_mon 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.document +5 -0
- data/.rspec +3 -0
- data/Gemfile +5 -0
- data/Gemfile.lock +28 -0
- data/LICENSE +20 -0
- data/README.rdoc +17 -0
- data/README.txt +43 -0
- data/Rakefile +53 -0
- data/VERSION +1 -0
- data/autotest/discover.rb +1 -0
- data/bin/statmon +45 -0
- data/lib/stat_mon.rb +29 -0
- data/lib/stat_mon/cli/execute.rb +33 -0
- data/lib/stat_mon/exceptions.rb +6 -0
- data/lib/stat_mon/listener.rb +33 -0
- data/lib/stat_mon/log.rb +11 -0
- data/lib/stat_mon/task.rb +36 -0
- data/pkg/stat_mon-0.1.0.gem +0 -0
- data/spec/spec_helper.rb +9 -0
- data/spec/stat_mon/log_spec.rb +13 -0
- data/spec/stat_mon/task_spec.rb +82 -0
- data/spec/stat_mon_spec.rb +42 -0
- data/stat_mon.gemspec +78 -0
- metadata +135 -0
data/.document
ADDED
data/.rspec
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
stat_mon (0.0.1)
|
5
|
+
eventmachine (>= 0.12.10)
|
6
|
+
|
7
|
+
GEM
|
8
|
+
specs:
|
9
|
+
diff-lcs (1.1.2)
|
10
|
+
eventmachine (0.12.10)
|
11
|
+
rspec (2.0.1)
|
12
|
+
rspec-core (~> 2.0.1)
|
13
|
+
rspec-expectations (~> 2.0.1)
|
14
|
+
rspec-mocks (~> 2.0.1)
|
15
|
+
rspec-core (2.0.1)
|
16
|
+
rspec-expectations (2.0.1)
|
17
|
+
diff-lcs (>= 1.1.2)
|
18
|
+
rspec-mocks (2.0.1)
|
19
|
+
rspec-core (~> 2.0.1)
|
20
|
+
rspec-expectations (~> 2.0.1)
|
21
|
+
|
22
|
+
PLATFORMS
|
23
|
+
ruby
|
24
|
+
|
25
|
+
DEPENDENCIES
|
26
|
+
eventmachine (>= 0.12.10)
|
27
|
+
rspec (>= 2.0.0)
|
28
|
+
stat_mon!
|
data/LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2010 Michael Wagner
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.rdoc
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
= StatMon
|
2
|
+
|
3
|
+
Easy way to monitor and log statistics on your server.
|
4
|
+
|
5
|
+
== Note on Patches/Pull Requests
|
6
|
+
|
7
|
+
* Fork the project.
|
8
|
+
* Make your feature addition or bug fix.
|
9
|
+
* Add tests for it. This is important so I don't break it in a
|
10
|
+
future version unintentionally.
|
11
|
+
* Commit, do not mess with rakefile, version, or history.
|
12
|
+
(if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
|
13
|
+
* Send me a pull request. Bonus points for topic branches.
|
14
|
+
|
15
|
+
== Copyright
|
16
|
+
|
17
|
+
Copyright (c) 2010 Michael Wagner. See LICENSE for details.
|
data/README.txt
ADDED
@@ -0,0 +1,43 @@
|
|
1
|
+
StatMon
|
2
|
+
by Michael Wagner ( @wagster )
|
3
|
+
|
4
|
+
== DESCRIPTION:
|
5
|
+
|
6
|
+
StatMon is an easy way to monitor and log statistics about your system.
|
7
|
+
|
8
|
+
== DOCUMENTATION:
|
9
|
+
|
10
|
+
COMING SOON.
|
11
|
+
|
12
|
+
== CONTRIBUTE:
|
13
|
+
|
14
|
+
Latest code is available at http://github.com/mikewagner/statmon.git
|
15
|
+
|
16
|
+
The 'master' branch can be cloned with:
|
17
|
+
|
18
|
+
$ git clone git://github.com/mikewagner/statmon.git
|
19
|
+
|
20
|
+
== LICENSE:
|
21
|
+
|
22
|
+
(The MIT License)
|
23
|
+
|
24
|
+
Copyright (c) 2010 Michael J Wagner
|
25
|
+
|
26
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
27
|
+
a copy of this software and associated documentation files (the
|
28
|
+
'Software'), to deal in the Software without restriction, including
|
29
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
30
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
31
|
+
permit persons to whom the Software is furnished to do so, subject to
|
32
|
+
the following conditions:
|
33
|
+
|
34
|
+
The above copyright notice and this permission notice shall be
|
35
|
+
included in all copies or substantial portions of the Software.
|
36
|
+
|
37
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
38
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
39
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
40
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
41
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
42
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
43
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Rakefile
ADDED
@@ -0,0 +1,53 @@
|
|
1
|
+
require 'rubygems'
|
2
|
+
require 'rake'
|
3
|
+
|
4
|
+
begin
|
5
|
+
require 'jeweler'
|
6
|
+
Jeweler::Tasks.new do |gem|
|
7
|
+
gem.name = "stat_mon"
|
8
|
+
gem.summary = %Q{Easy way to monitor and log statistics on your server.}
|
9
|
+
gem.description = %Q{Easy way to monitor and log statistics on your server.}
|
10
|
+
gem.email = "mwagner@digitalinsites.com"
|
11
|
+
gem.homepage = "http://github.com/mikewagner/statmon"
|
12
|
+
gem.authors = ["Michael Wagner"]
|
13
|
+
gem.executables = ['statmon']
|
14
|
+
|
15
|
+
gem.files.exclude 'monitor.stats'
|
16
|
+
|
17
|
+
gem.add_dependency "eventmachine", ">= 0.12.10"
|
18
|
+
|
19
|
+
gem.add_development_dependency "rspec-core", ">= 2.0.1"
|
20
|
+
gem.add_development_dependency "rspec-expectations", ">= 2.0.1"
|
21
|
+
|
22
|
+
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
23
|
+
end
|
24
|
+
Jeweler::GemcutterTasks.new
|
25
|
+
rescue LoadError
|
26
|
+
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
|
27
|
+
end
|
28
|
+
|
29
|
+
require 'spec/rake/spectask'
|
30
|
+
Spec::Rake::SpecTask.new(:spec) do |spec|
|
31
|
+
spec.libs << 'lib' << 'spec'
|
32
|
+
spec.spec_files = FileList['spec/**/*_spec.rb']
|
33
|
+
end
|
34
|
+
|
35
|
+
Spec::Rake::SpecTask.new(:rcov) do |spec|
|
36
|
+
spec.libs << 'lib' << 'spec'
|
37
|
+
spec.pattern = 'spec/**/*_spec.rb'
|
38
|
+
spec.rcov = true
|
39
|
+
end
|
40
|
+
|
41
|
+
task :spec => :check_dependencies
|
42
|
+
|
43
|
+
task :default => :spec
|
44
|
+
|
45
|
+
require 'rake/rdoctask'
|
46
|
+
Rake::RDocTask.new do |rdoc|
|
47
|
+
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
48
|
+
|
49
|
+
rdoc.rdoc_dir = 'rdoc'
|
50
|
+
rdoc.title = "test #{version}"
|
51
|
+
rdoc.rdoc_files.include('README*')
|
52
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
53
|
+
end
|
data/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
0.1.0
|
@@ -0,0 +1 @@
|
|
1
|
+
Autotest.add_discovery { "rspec2" }
|
data/bin/statmon
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
$:.unshift File.join( File.dirname(__FILE__), '..', 'lib' )
|
3
|
+
|
4
|
+
require 'rubygems'
|
5
|
+
require 'optparse'
|
6
|
+
require 'yaml'
|
7
|
+
require 'stat_mon'
|
8
|
+
|
9
|
+
options = {}
|
10
|
+
|
11
|
+
opts = OptionParser.new do |opts|
|
12
|
+
opts.banner = <<-EOF
|
13
|
+
Usage:
|
14
|
+
Starting:
|
15
|
+
statmon [-c <config file>]
|
16
|
+
|
17
|
+
Querying:
|
18
|
+
statmon -v
|
19
|
+
|
20
|
+
Options:
|
21
|
+
EOF
|
22
|
+
|
23
|
+
opts.on("-cCONFIG", "--config-file CONFIG", "Configuration file") do |x|
|
24
|
+
options[:config] = x
|
25
|
+
end
|
26
|
+
|
27
|
+
opts.on("-v", "--version", "Print the version number and exit") do
|
28
|
+
options[:version] = true
|
29
|
+
end
|
30
|
+
|
31
|
+
end
|
32
|
+
|
33
|
+
opts.parse!
|
34
|
+
|
35
|
+
begin
|
36
|
+
if !options[:config] && options[:version]
|
37
|
+
require 'stat_mon'
|
38
|
+
StatMon.version
|
39
|
+
else
|
40
|
+
require 'stat_mon/cli/execute'
|
41
|
+
StatMon::CLI::Execute.new(options)
|
42
|
+
end
|
43
|
+
rescue Exception => e
|
44
|
+
puts e
|
45
|
+
end
|
data/lib/stat_mon.rb
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# Make sure you have the correct versions of the gems (see gemspec) in your load path.
|
3
|
+
require 'eventmachine'
|
4
|
+
require 'logger'
|
5
|
+
|
6
|
+
require 'stat_mon/cli/execute'
|
7
|
+
|
8
|
+
module StatMon
|
9
|
+
|
10
|
+
VERSION = '0.1.0'
|
11
|
+
|
12
|
+
|
13
|
+
autoload :DuplicateMonitorName, 'stat_mon/exceptions'
|
14
|
+
|
15
|
+
autoload :Listener, 'stat_mon/listener'
|
16
|
+
autoload :Task, 'stat_mon/task'
|
17
|
+
autoload :Log, 'stat_mon/log'
|
18
|
+
autoload :Version, 'stat_mon/version'
|
19
|
+
|
20
|
+
extend Listener
|
21
|
+
|
22
|
+
|
23
|
+
|
24
|
+
def self.version
|
25
|
+
puts "Version #{VERSION}"
|
26
|
+
end
|
27
|
+
|
28
|
+
|
29
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
module StatMon
|
2
|
+
module CLI
|
3
|
+
class Execute
|
4
|
+
|
5
|
+
def initialize(params)
|
6
|
+
@params = params
|
7
|
+
start
|
8
|
+
end
|
9
|
+
|
10
|
+
def start
|
11
|
+
StatMon.init
|
12
|
+
config = load_config( @params[:config] )
|
13
|
+
|
14
|
+
StatMon.start
|
15
|
+
end
|
16
|
+
|
17
|
+
def load_config( config )
|
18
|
+
abort "Unable to find config file" unless File.exist?( config )
|
19
|
+
load_stat_file( config )
|
20
|
+
end
|
21
|
+
|
22
|
+
|
23
|
+
def load_stat_file( stat_file )
|
24
|
+
load File.expand_path( stat_file )
|
25
|
+
rescue Exception => e
|
26
|
+
puts "There was an error in #{stat_file}"
|
27
|
+
puts "\t" + e.message
|
28
|
+
puts "\t" + e.backtrace.join("\n\y\t")
|
29
|
+
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
module StatMon
|
2
|
+
module Listener
|
3
|
+
|
4
|
+
def init
|
5
|
+
@monitors = Hash.new
|
6
|
+
end
|
7
|
+
|
8
|
+
def monitors
|
9
|
+
@monitors
|
10
|
+
end
|
11
|
+
|
12
|
+
def monitor(&block)
|
13
|
+
task = Task.new
|
14
|
+
yield(task)
|
15
|
+
|
16
|
+
raise DuplicateMonitorName, "Duplicate monitor name" if monitors.has_key? task.name
|
17
|
+
monitors[task.name] = task
|
18
|
+
end
|
19
|
+
|
20
|
+
def start
|
21
|
+
EventMachine.run do
|
22
|
+
monitors.each do |name, task|
|
23
|
+
EventMachine.add_periodic_timer(task.interval) do
|
24
|
+
EventMachine.system( task.process ) do |output, status|
|
25
|
+
task.log output
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
end
|
33
|
+
end
|
data/lib/stat_mon/log.rb
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
module StatMon
|
2
|
+
class Task
|
3
|
+
|
4
|
+
attr_accessor :name, :process, :interval
|
5
|
+
|
6
|
+
def initialize(&block)
|
7
|
+
yield(self) if block_given?
|
8
|
+
end
|
9
|
+
|
10
|
+
def valid?
|
11
|
+
valid = true
|
12
|
+
valid = false if self.name.nil?
|
13
|
+
valid = false if self.process.nil?
|
14
|
+
valid
|
15
|
+
end
|
16
|
+
|
17
|
+
def log( msg )
|
18
|
+
loggers.each do |logger|
|
19
|
+
logger.info( msg )
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
def loggers
|
24
|
+
@loggers ||= Array.new
|
25
|
+
end
|
26
|
+
|
27
|
+
def logger( opts )
|
28
|
+
logger = nil
|
29
|
+
if opts.has_key?(:file)
|
30
|
+
logger = Log.new( opts[:file] )
|
31
|
+
end
|
32
|
+
loggers << logger if logger
|
33
|
+
end
|
34
|
+
|
35
|
+
end
|
36
|
+
end
|
Binary file
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
|
2
|
+
|
3
|
+
describe StatMon::Log do
|
4
|
+
|
5
|
+
context "initialization" do
|
6
|
+
it "should return logger" do
|
7
|
+
log = StatMon::Log.new('foo')
|
8
|
+
log.should be_instance_of StatMon::Log
|
9
|
+
log.class.superclass.should == Logger
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
13
|
+
end
|
@@ -0,0 +1,82 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
|
2
|
+
|
3
|
+
describe StatMon::Task do
|
4
|
+
|
5
|
+
context "valid?" do
|
6
|
+
|
7
|
+
before do
|
8
|
+
@task = StatMon::Task.new do |t|
|
9
|
+
t.name = 'foo'
|
10
|
+
t.interval = 5
|
11
|
+
t.process = 'bar'
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
it "should return true" do
|
16
|
+
@task.should be_valid
|
17
|
+
end
|
18
|
+
|
19
|
+
it "should return false if no name" do
|
20
|
+
@task.name = nil
|
21
|
+
@task.should_not be_valid
|
22
|
+
end
|
23
|
+
|
24
|
+
it "should return false if no process" do
|
25
|
+
@task.process = nil
|
26
|
+
@task.should_not be_valid
|
27
|
+
end
|
28
|
+
|
29
|
+
end
|
30
|
+
|
31
|
+
|
32
|
+
context "loggers" do
|
33
|
+
before do
|
34
|
+
@task = StatMon::Task.new
|
35
|
+
end
|
36
|
+
|
37
|
+
it "should default to empty array" do
|
38
|
+
@task.loggers.should == Array.new
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
|
43
|
+
context "logger" do
|
44
|
+
before do
|
45
|
+
@task = StatMon::Task.new
|
46
|
+
end
|
47
|
+
|
48
|
+
it "should store logger" do
|
49
|
+
logger = nil
|
50
|
+
@task.logger(:file => '/dev/null')
|
51
|
+
|
52
|
+
@task.should have(1).loggers
|
53
|
+
end
|
54
|
+
|
55
|
+
it "should store multiple loggers" do
|
56
|
+
@task.logger(:file => '/dev/null')
|
57
|
+
@task.logger(:file => '/dev/null')
|
58
|
+
@task.should have(2).loggers
|
59
|
+
end
|
60
|
+
|
61
|
+
end
|
62
|
+
|
63
|
+
context "log" do
|
64
|
+
|
65
|
+
before do
|
66
|
+
@task = StatMon::Task.new do |t|
|
67
|
+
t.name = 'foo'
|
68
|
+
end
|
69
|
+
@logger = StatMon::Log.new( '/dev/null' )
|
70
|
+
@task.stub!(:loggers).and_return( [@logger] )
|
71
|
+
end
|
72
|
+
|
73
|
+
it "should log output to each logger" do
|
74
|
+
@logger.should_receive(:info).and_return(:true)
|
75
|
+
@task.log('The quick brown fox jumps over the lazy dog')
|
76
|
+
end
|
77
|
+
|
78
|
+
|
79
|
+
end
|
80
|
+
|
81
|
+
|
82
|
+
end
|
@@ -0,0 +1,42 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
|
+
|
3
|
+
describe StatMon do
|
4
|
+
|
5
|
+
context "#monitors" do
|
6
|
+
it "should default to empty hash" do
|
7
|
+
StatMon.init
|
8
|
+
StatMon.monitors.should == Hash.new
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
context "#monitor" do
|
13
|
+
before do
|
14
|
+
StatMon.init
|
15
|
+
end
|
16
|
+
|
17
|
+
it "should store monitor" do
|
18
|
+
monitor = nil
|
19
|
+
StatMon.monitor do |m|
|
20
|
+
m.name = 'iostat'
|
21
|
+
monitor = m
|
22
|
+
end
|
23
|
+
StatMon.should have(1).monitors
|
24
|
+
StatMon.monitors['iostat'].should == monitor
|
25
|
+
end
|
26
|
+
|
27
|
+
it "should allow multiple monitors" do
|
28
|
+
StatMon.monitor { |m| m.name = 'foo' }
|
29
|
+
StatMon.monitor { |m| m.name = 'bar' }
|
30
|
+
StatMon.should have(2).monitors
|
31
|
+
end
|
32
|
+
|
33
|
+
it "should raise error for duplicate monitor name" do
|
34
|
+
StatMon.monitor { |m| m.name = 'test' }
|
35
|
+
lambda {
|
36
|
+
StatMon.monitor { |m| m.name = 'test' }
|
37
|
+
}.should raise_error
|
38
|
+
end
|
39
|
+
|
40
|
+
end
|
41
|
+
|
42
|
+
end
|
data/stat_mon.gemspec
ADDED
@@ -0,0 +1,78 @@
|
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
|
6
|
+
Gem::Specification.new do |s|
|
7
|
+
s.name = %q{stat_mon}
|
8
|
+
s.version = "0.1.0"
|
9
|
+
|
10
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
+
s.authors = ["Michael Wagner"]
|
12
|
+
s.date = %q{2011-03-01}
|
13
|
+
s.default_executable = %q{statmon}
|
14
|
+
s.description = %q{Easy way to monitor and log statistics on your server.}
|
15
|
+
s.email = %q{mwagner@digitalinsites.com}
|
16
|
+
s.executables = ["statmon"]
|
17
|
+
s.extra_rdoc_files = [
|
18
|
+
"LICENSE",
|
19
|
+
"README.rdoc",
|
20
|
+
"README.txt"
|
21
|
+
]
|
22
|
+
s.files = [
|
23
|
+
".document",
|
24
|
+
".rspec",
|
25
|
+
"Gemfile",
|
26
|
+
"Gemfile.lock",
|
27
|
+
"LICENSE",
|
28
|
+
"README.rdoc",
|
29
|
+
"README.txt",
|
30
|
+
"Rakefile",
|
31
|
+
"VERSION",
|
32
|
+
"autotest/discover.rb",
|
33
|
+
"bin/statmon",
|
34
|
+
"lib/stat_mon.rb",
|
35
|
+
"lib/stat_mon/cli/execute.rb",
|
36
|
+
"lib/stat_mon/exceptions.rb",
|
37
|
+
"lib/stat_mon/listener.rb",
|
38
|
+
"lib/stat_mon/log.rb",
|
39
|
+
"lib/stat_mon/task.rb",
|
40
|
+
"pkg/stat_mon-0.1.0.gem",
|
41
|
+
"spec/spec_helper.rb",
|
42
|
+
"spec/stat_mon/log_spec.rb",
|
43
|
+
"spec/stat_mon/task_spec.rb",
|
44
|
+
"spec/stat_mon_spec.rb",
|
45
|
+
"stat_mon.gemspec"
|
46
|
+
]
|
47
|
+
s.homepage = %q{http://github.com/mikewagner/statmon}
|
48
|
+
s.rdoc_options = ["--charset=UTF-8"]
|
49
|
+
s.require_paths = ["lib"]
|
50
|
+
s.rubygems_version = %q{1.3.7}
|
51
|
+
s.summary = %q{Easy way to monitor and log statistics on your server.}
|
52
|
+
s.test_files = [
|
53
|
+
"spec/spec_helper.rb",
|
54
|
+
"spec/stat_mon/log_spec.rb",
|
55
|
+
"spec/stat_mon/task_spec.rb",
|
56
|
+
"spec/stat_mon_spec.rb"
|
57
|
+
]
|
58
|
+
|
59
|
+
if s.respond_to? :specification_version then
|
60
|
+
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
61
|
+
s.specification_version = 3
|
62
|
+
|
63
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
64
|
+
s.add_runtime_dependency(%q<eventmachine>, [">= 0.12.10"])
|
65
|
+
s.add_development_dependency(%q<rspec-core>, [">= 2.0.1"])
|
66
|
+
s.add_development_dependency(%q<rspec-expectations>, [">= 2.0.1"])
|
67
|
+
else
|
68
|
+
s.add_dependency(%q<eventmachine>, [">= 0.12.10"])
|
69
|
+
s.add_dependency(%q<rspec-core>, [">= 2.0.1"])
|
70
|
+
s.add_dependency(%q<rspec-expectations>, [">= 2.0.1"])
|
71
|
+
end
|
72
|
+
else
|
73
|
+
s.add_dependency(%q<eventmachine>, [">= 0.12.10"])
|
74
|
+
s.add_dependency(%q<rspec-core>, [">= 2.0.1"])
|
75
|
+
s.add_dependency(%q<rspec-expectations>, [">= 2.0.1"])
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
metadata
ADDED
@@ -0,0 +1,135 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: stat_mon
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
prerelease: false
|
5
|
+
segments:
|
6
|
+
- 0
|
7
|
+
- 1
|
8
|
+
- 0
|
9
|
+
version: 0.1.0
|
10
|
+
platform: ruby
|
11
|
+
authors:
|
12
|
+
- Michael Wagner
|
13
|
+
autorequire:
|
14
|
+
bindir: bin
|
15
|
+
cert_chain: []
|
16
|
+
|
17
|
+
date: 2011-03-01 00:00:00 -06:00
|
18
|
+
default_executable: statmon
|
19
|
+
dependencies:
|
20
|
+
- !ruby/object:Gem::Dependency
|
21
|
+
name: eventmachine
|
22
|
+
prerelease: false
|
23
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
24
|
+
none: false
|
25
|
+
requirements:
|
26
|
+
- - ">="
|
27
|
+
- !ruby/object:Gem::Version
|
28
|
+
segments:
|
29
|
+
- 0
|
30
|
+
- 12
|
31
|
+
- 10
|
32
|
+
version: 0.12.10
|
33
|
+
type: :runtime
|
34
|
+
version_requirements: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
name: rspec-core
|
37
|
+
prerelease: false
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ">="
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
segments:
|
44
|
+
- 2
|
45
|
+
- 0
|
46
|
+
- 1
|
47
|
+
version: 2.0.1
|
48
|
+
type: :development
|
49
|
+
version_requirements: *id002
|
50
|
+
- !ruby/object:Gem::Dependency
|
51
|
+
name: rspec-expectations
|
52
|
+
prerelease: false
|
53
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
54
|
+
none: false
|
55
|
+
requirements:
|
56
|
+
- - ">="
|
57
|
+
- !ruby/object:Gem::Version
|
58
|
+
segments:
|
59
|
+
- 2
|
60
|
+
- 0
|
61
|
+
- 1
|
62
|
+
version: 2.0.1
|
63
|
+
type: :development
|
64
|
+
version_requirements: *id003
|
65
|
+
description: Easy way to monitor and log statistics on your server.
|
66
|
+
email: mwagner@digitalinsites.com
|
67
|
+
executables:
|
68
|
+
- statmon
|
69
|
+
extensions: []
|
70
|
+
|
71
|
+
extra_rdoc_files:
|
72
|
+
- LICENSE
|
73
|
+
- README.rdoc
|
74
|
+
- README.txt
|
75
|
+
files:
|
76
|
+
- .document
|
77
|
+
- .rspec
|
78
|
+
- Gemfile
|
79
|
+
- Gemfile.lock
|
80
|
+
- LICENSE
|
81
|
+
- README.rdoc
|
82
|
+
- README.txt
|
83
|
+
- Rakefile
|
84
|
+
- VERSION
|
85
|
+
- autotest/discover.rb
|
86
|
+
- bin/statmon
|
87
|
+
- lib/stat_mon.rb
|
88
|
+
- lib/stat_mon/cli/execute.rb
|
89
|
+
- lib/stat_mon/exceptions.rb
|
90
|
+
- lib/stat_mon/listener.rb
|
91
|
+
- lib/stat_mon/log.rb
|
92
|
+
- lib/stat_mon/task.rb
|
93
|
+
- pkg/stat_mon-0.1.0.gem
|
94
|
+
- spec/spec_helper.rb
|
95
|
+
- spec/stat_mon/log_spec.rb
|
96
|
+
- spec/stat_mon/task_spec.rb
|
97
|
+
- spec/stat_mon_spec.rb
|
98
|
+
- stat_mon.gemspec
|
99
|
+
has_rdoc: true
|
100
|
+
homepage: http://github.com/mikewagner/statmon
|
101
|
+
licenses: []
|
102
|
+
|
103
|
+
post_install_message:
|
104
|
+
rdoc_options:
|
105
|
+
- --charset=UTF-8
|
106
|
+
require_paths:
|
107
|
+
- lib
|
108
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
109
|
+
none: false
|
110
|
+
requirements:
|
111
|
+
- - ">="
|
112
|
+
- !ruby/object:Gem::Version
|
113
|
+
segments:
|
114
|
+
- 0
|
115
|
+
version: "0"
|
116
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
117
|
+
none: false
|
118
|
+
requirements:
|
119
|
+
- - ">="
|
120
|
+
- !ruby/object:Gem::Version
|
121
|
+
segments:
|
122
|
+
- 0
|
123
|
+
version: "0"
|
124
|
+
requirements: []
|
125
|
+
|
126
|
+
rubyforge_project:
|
127
|
+
rubygems_version: 1.3.7
|
128
|
+
signing_key:
|
129
|
+
specification_version: 3
|
130
|
+
summary: Easy way to monitor and log statistics on your server.
|
131
|
+
test_files:
|
132
|
+
- spec/spec_helper.rb
|
133
|
+
- spec/stat_mon/log_spec.rb
|
134
|
+
- spec/stat_mon/task_spec.rb
|
135
|
+
- spec/stat_mon_spec.rb
|