daikon 0.8.2 → 0.8.4

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,30 +1,11 @@
1
- require 'rubygems'
2
- require 'jeweler'
3
- require './lib/daikon'
4
-
5
- Jeweler::Tasks.new do |gem|
6
- # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
7
- gem.version = Daikon::VERSION
8
-
9
- gem.name = "daikon"
10
- gem.homepage = "http://github.com/qrush/daikon"
11
- gem.license = "MIT"
12
- gem.summary = gem.description = %Q{daikon, a radishapp.com client}
13
- gem.email = "nick@quaran.to"
14
- gem.authors = ["Nick Quaranto"]
15
- gem.required_ruby_version = '>= 1.8.7'
16
- end
17
- Jeweler::RubygemsDotOrgTasks.new
18
-
19
1
  require 'rspec/core'
20
2
  require 'rspec/core/rake_task'
21
3
  RSpec::Core::RakeTask.new(:spec) do |spec|
22
4
  spec.pattern = FileList['spec/**/*_spec.rb']
5
+ spec.ruby_opts = "-Ilib"
23
6
  end
24
7
 
25
- require 'cucumber/rake/task'
26
- Cucumber::Rake::Task.new(:features)
27
-
8
+ desc "run tests"
28
9
  task :default => :spec
29
10
 
30
11
  def parse_monitor
data/daikon.gemspec CHANGED
@@ -1,19 +1,15 @@
1
- # Generated by jeweler
2
- # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
- # -*- encoding: utf-8 -*-
1
+ require './lib/daikon/version'
5
2
 
6
3
  Gem::Specification.new do |s|
7
4
  s.name = %q{daikon}
8
- s.version = "0.8.2"
5
+ s.version = Daikon::VERSION
9
6
 
10
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
- s.authors = ["Nick Quaranto"]
12
- s.date = %q{2011-03-22}
13
- s.default_executable = %q{daikon}
8
+ s.authors = [%q{Nick Quaranto}]
9
+ s.date = %q{2011-05-30}
14
10
  s.description = %q{daikon, a radishapp.com client}
15
11
  s.email = %q{nick@quaran.to}
16
- s.executables = ["daikon"]
12
+ s.executables = [%q{daikon}]
17
13
  s.extra_rdoc_files = [
18
14
  "README.rdoc"
19
15
  ]
@@ -34,6 +30,7 @@ Gem::Specification.new do |s|
34
30
  "lib/daikon/daemons_hacks.rb",
35
31
  "lib/daikon/monitor.rb",
36
32
  "lib/daikon/redis_hacks.rb",
33
+ "lib/daikon/version.rb",
37
34
  "spec/client_spec.rb",
38
35
  "spec/configuration_spec.rb",
39
36
  "spec/daemon_spec.rb",
@@ -41,10 +38,10 @@ Gem::Specification.new do |s|
41
38
  "spec/spec_helper.rb"
42
39
  ]
43
40
  s.homepage = %q{http://github.com/qrush/daikon}
44
- s.licenses = ["MIT"]
45
- s.require_paths = ["lib"]
41
+ s.licenses = [%q{MIT}]
42
+ s.require_paths = [%q{lib}]
46
43
  s.required_ruby_version = Gem::Requirement.new(">= 1.8.7")
47
- s.rubygems_version = %q{1.6.1}
44
+ s.rubygems_version = %q{1.8.1}
48
45
  s.summary = %q{daikon, a radishapp.com client}
49
46
  s.test_files = [
50
47
  "spec/client_spec.rb",
data/lib/daikon.rb CHANGED
@@ -1,5 +1,3 @@
1
- require 'rubygems'
2
-
3
1
  require 'logger'
4
2
  require 'shellwords'
5
3
  require 'set'
@@ -12,20 +10,10 @@ require 'daemons'
12
10
  require 'json'
13
11
  require 'redis'
14
12
 
15
- __DIR__ = File.dirname(__FILE__)
16
-
17
- $LOAD_PATH.unshift __DIR__ unless
18
- $LOAD_PATH.include?(__DIR__) ||
19
- $LOAD_PATH.include?(File.expand_path(__DIR__))
20
-
13
+ require 'daikon/version'
21
14
  require 'daikon/configuration'
22
15
  require 'daikon/client'
23
16
  require 'daikon/daemon'
24
17
  require 'daikon/monitor'
25
-
26
18
  require 'daikon/daemons_hacks'
27
19
  require 'daikon/redis_hacks'
28
-
29
- module Daikon
30
- VERSION = "0.8.2"
31
- end
data/lib/daikon/client.rb CHANGED
@@ -59,8 +59,7 @@ module Daikon
59
59
 
60
60
  def rotate_monitor(start, stop)
61
61
  payload = monitor.rotate.merge({
62
- "start" => start,
63
- "stop" => stop
62
+ "created_at" => stop
64
63
  })
65
64
 
66
65
  push :post, "/api/v1/summaries.json", payload
data/lib/daikon/daemon.rb CHANGED
@@ -8,7 +8,7 @@ module Daikon
8
8
  end
9
9
 
10
10
  def self.sleep_time
11
- @@sleep_time ||= 1
11
+ @@sleep_time ||= 0.5
12
12
  end
13
13
 
14
14
  def self.run=(run)
@@ -0,0 +1,3 @@
1
+ module Daikon
2
+ VERSION = "0.8.4"
3
+ end
data/spec/client_spec.rb CHANGED
@@ -100,7 +100,7 @@ describe Daikon::Client, "rotate monitor" do
100
100
  let(:now) { "2011-01-19T18:23:55-05:00" }
101
101
  let(:past) { "2011-01-19T18:23:54-05:00" }
102
102
  let(:payload) do
103
- data.merge("start" => past, "stop" => now)
103
+ data.merge("created_at" => now)
104
104
  end
105
105
  let(:data) do
106
106
  {"commands" => {"GET" => 42},
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: daikon
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.8.2
5
+ version: 0.8.4
6
6
  platform: ruby
7
7
  authors:
8
8
  - Nick Quaranto
@@ -10,11 +10,11 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-03-22 00:00:00 -04:00
14
- default_executable: daikon
13
+ date: 2011-05-30 00:00:00 Z
15
14
  dependencies:
16
15
  - !ruby/object:Gem::Dependency
17
16
  name: daemons
17
+ prerelease: false
18
18
  requirement: &id001 !ruby/object:Gem::Requirement
19
19
  none: false
20
20
  requirements:
@@ -22,10 +22,10 @@ dependencies:
22
22
  - !ruby/object:Gem::Version
23
23
  version: 1.1.0
24
24
  type: :runtime
25
- prerelease: false
26
25
  version_requirements: *id001
27
26
  - !ruby/object:Gem::Dependency
28
27
  name: excon
28
+ prerelease: false
29
29
  requirement: &id002 !ruby/object:Gem::Requirement
30
30
  none: false
31
31
  requirements:
@@ -33,10 +33,10 @@ dependencies:
33
33
  - !ruby/object:Gem::Version
34
34
  version: 0.5.6
35
35
  type: :runtime
36
- prerelease: false
37
36
  version_requirements: *id002
38
37
  - !ruby/object:Gem::Dependency
39
38
  name: json_pure
39
+ prerelease: false
40
40
  requirement: &id003 !ruby/object:Gem::Requirement
41
41
  none: false
42
42
  requirements:
@@ -44,10 +44,10 @@ dependencies:
44
44
  - !ruby/object:Gem::Version
45
45
  version: 1.4.6
46
46
  type: :runtime
47
- prerelease: false
48
47
  version_requirements: *id003
49
48
  - !ruby/object:Gem::Dependency
50
49
  name: redis
50
+ prerelease: false
51
51
  requirement: &id004 !ruby/object:Gem::Requirement
52
52
  none: false
53
53
  requirements:
@@ -55,10 +55,10 @@ dependencies:
55
55
  - !ruby/object:Gem::Version
56
56
  version: 2.1.1
57
57
  type: :runtime
58
- prerelease: false
59
58
  version_requirements: *id004
60
59
  - !ruby/object:Gem::Dependency
61
60
  name: bourne
61
+ prerelease: false
62
62
  requirement: &id005 !ruby/object:Gem::Requirement
63
63
  none: false
64
64
  requirements:
@@ -66,10 +66,10 @@ dependencies:
66
66
  - !ruby/object:Gem::Version
67
67
  version: "0"
68
68
  type: :development
69
- prerelease: false
70
69
  version_requirements: *id005
71
70
  - !ruby/object:Gem::Dependency
72
71
  name: cucumber
72
+ prerelease: false
73
73
  requirement: &id006 !ruby/object:Gem::Requirement
74
74
  none: false
75
75
  requirements:
@@ -77,10 +77,10 @@ dependencies:
77
77
  - !ruby/object:Gem::Version
78
78
  version: "0"
79
79
  type: :development
80
- prerelease: false
81
80
  version_requirements: *id006
82
81
  - !ruby/object:Gem::Dependency
83
82
  name: jeweler
83
+ prerelease: false
84
84
  requirement: &id007 !ruby/object:Gem::Requirement
85
85
  none: false
86
86
  requirements:
@@ -88,10 +88,10 @@ dependencies:
88
88
  - !ruby/object:Gem::Version
89
89
  version: "0"
90
90
  type: :development
91
- prerelease: false
92
91
  version_requirements: *id007
93
92
  - !ruby/object:Gem::Dependency
94
93
  name: rspec
94
+ prerelease: false
95
95
  requirement: &id008 !ruby/object:Gem::Requirement
96
96
  none: false
97
97
  requirements:
@@ -99,10 +99,10 @@ dependencies:
99
99
  - !ruby/object:Gem::Version
100
100
  version: "0"
101
101
  type: :development
102
- prerelease: false
103
102
  version_requirements: *id008
104
103
  - !ruby/object:Gem::Dependency
105
104
  name: timecop
105
+ prerelease: false
106
106
  requirement: &id009 !ruby/object:Gem::Requirement
107
107
  none: false
108
108
  requirements:
@@ -110,7 +110,6 @@ dependencies:
110
110
  - !ruby/object:Gem::Version
111
111
  version: "0"
112
112
  type: :development
113
- prerelease: false
114
113
  version_requirements: *id009
115
114
  description: daikon, a radishapp.com client
116
115
  email: nick@quaran.to
@@ -137,12 +136,12 @@ files:
137
136
  - lib/daikon/daemons_hacks.rb
138
137
  - lib/daikon/monitor.rb
139
138
  - lib/daikon/redis_hacks.rb
139
+ - lib/daikon/version.rb
140
140
  - spec/client_spec.rb
141
141
  - spec/configuration_spec.rb
142
142
  - spec/daemon_spec.rb
143
143
  - spec/monitor_spec.rb
144
144
  - spec/spec_helper.rb
145
- has_rdoc: true
146
145
  homepage: http://github.com/qrush/daikon
147
146
  licenses:
148
147
  - MIT
@@ -166,7 +165,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
166
165
  requirements: []
167
166
 
168
167
  rubyforge_project:
169
- rubygems_version: 1.6.1
168
+ rubygems_version: 1.8.1
170
169
  signing_key:
171
170
  specification_version: 3
172
171
  summary: daikon, a radishapp.com client