librato-rails 0.10.0.pre1 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
data.tar.gz.sig ADDED
Binary file
data/CHANGELOG.md CHANGED
@@ -1,8 +1,8 @@
1
- ### Version 0.10.0.pre1
1
+ ### Version 0.10.0
2
2
  * Add render instrumentation metrics
3
3
  * Add cache instrumentation metrics
4
4
  * Add metrics on HTTP method use
5
- * Rack middleware moved from end of stack to beginning, improving value of rack metrics (Thibaud Guillaume-Gentil)
5
+ * Rack middleware now racks itself first, improving value of rack metrics (Thibaud Guillaume-Gentil)
6
6
  * Add ability to control startup with LIBRATO_AUTORUN
7
7
  * Add ability to force startup in console mode with LIBRATO_AUTORUN
8
8
  * Refactor to use librato-rack
data/Rakefile CHANGED
@@ -4,21 +4,17 @@ begin
4
4
  rescue LoadError
5
5
  puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
6
6
  end
7
- begin
8
- require 'rdoc/task'
9
- rescue LoadError
10
- require 'rdoc/rdoc'
11
- require 'rake/rdoctask'
12
- RDoc::Task = Rake::RDocTask
13
- end
14
7
 
15
- RDoc::Task.new(:rdoc) do |rdoc|
16
- rdoc.rdoc_dir = 'rdoc'
17
- rdoc.title = 'LibratoRails'
18
- rdoc.options << '--line-numbers'
19
- rdoc.rdoc_files.include('README.rdoc')
20
- rdoc.rdoc_files.include('lib/**/*.rb')
8
+ task 'before_build' do
9
+ signing_key = File.expand_path("~/.gem/librato-private_key.pem")
10
+ if File.exists?(signing_key)
11
+ puts "Key found: signing gem..."
12
+ ENV['GEM_SIGNING_KEY'] = signing_key
13
+ else
14
+ puts "WARN: signing key not found, gem not signed"
15
+ end
21
16
  end
17
+ task :build => :before_build
22
18
 
23
19
  # IRB
24
20
  desc "Open an irb session preloaded with this library"
@@ -37,5 +33,4 @@ Rake::TestTask.new(:test) do |t|
37
33
  t.verbose = false
38
34
  end
39
35
 
40
-
41
36
  task :default => :test
@@ -30,6 +30,7 @@ module Librato
30
30
 
31
31
  # respect autorun and log_level env vars regardless of config method
32
32
  self.autorun = detect_autorun
33
+ self.log_level = :info if log_level.blank?
33
34
  self.log_level = ENV['LIBRATO_LOG_LEVEL'] if ENV['LIBRATO_LOG_LEVEL']
34
35
  end
35
36
 
@@ -30,10 +30,10 @@ module Librato
30
30
  end
31
31
 
32
32
  if http_method
33
- http_method.downcase!
33
+ verb = http_method.to_s.downcase
34
34
  r.group 'method' do |m|
35
- m.increment http_method
36
- m.timing "#{http_method}.time", event.duration
35
+ m.increment verb
36
+ m.timing "#{verb}.time", event.duration
37
37
  end
38
38
  end
39
39
 
@@ -1,5 +1,5 @@
1
1
  module Librato
2
2
  module Rails
3
- VERSION = "0.10.0.pre1"
3
+ VERSION = "0.10.0"
4
4
  end
5
5
  end
@@ -0,0 +1,4 @@
1
+ test:
2
+ user: 'test@bar.com'
3
+ token: 'test key'
4
+ log_level: ''
@@ -65,6 +65,11 @@ module Librato
65
65
  assert_equal 30, config.flush_interval # from config file
66
66
  end
67
67
 
68
+ def test_empty_config_file_doesnt_break_log_level
69
+ config = fixture_config('empty')
70
+ assert_equal :info, config.log_level, 'should be default'
71
+ end
72
+
68
73
  def fixture_config(file='librato')
69
74
  fixture_config = File.join(File.dirname(__FILE__), "../fixtures/config/#{file}.yml")
70
75
  Configuration.new(:config_file => fixture_config)
metadata CHANGED
@@ -1,15 +1,43 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: librato-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0.pre1
5
- prerelease: 7
4
+ version: 0.10.0
5
+ prerelease:
6
6
  platform: ruby
7
7
  authors:
8
8
  - Matt Sanders
9
9
  autorequire:
10
10
  bindir: bin
11
- cert_chain: []
12
- date: 2013-08-23 00:00:00.000000000 Z
11
+ cert_chain:
12
+ - !binary |-
13
+ LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUROakNDQWg2Z0F3SUJB
14
+ Z0lCQURBTkJna3Foa2lHOXcwQkFRVUZBREJCTVJFd0R3WURWUVFEREFo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lTc0VmcVIrRExkdjFWQWNkbXhhd3FDK1ptRzRGcHhaaHVIaGFvVXVpMzVB
32
+ b1FqelNpSEVVTkRUSXUzdTcKVGNzWXdYTVB6dXl6WkpKS1h2QkttU2I5bVdK
33
+ OTlET0g4MW9VbU96WDdqQ2xRWFpIcm5GdEhkQVJjTFFzUG1nYQo0RGgrZldY
34
+ V3hQSjZma3ZnODI2dko0cERtbDdPbzlzQ1hUcEMya2kvNVZla1RYa3BGclVz
35
+ UVJYamxYUGttVDMvCnhhODU4QkdSanZVNTlXUEUxM1FHaWJhN1lJZUh0UkV2
36
+ Tng0MkpJZm9KTVY3NG9mcktJdVR3OUNNdG8yZ3o5WHgKS3gxbmNuMDdBK2JK
37
+ bktaNmhlblFBRjFDSDk2WmNxY0pIMTc5UzJ0SWlLRE04a2VlUklVT1BDM1dU
38
+ MGZhb2svMgpnQTJvemRyODUxYy9uQT09Ci0tLS0tRU5EIENFUlRJRklDQVRF
39
+ LS0tLS0K
40
+ date: 2013-08-27 00:00:00.000000000 Z
13
41
  dependencies:
14
42
  - !ruby/object:Gem::Dependency
15
43
  name: rails
@@ -34,7 +62,7 @@ dependencies:
34
62
  requirements:
35
63
  - - ~>
36
64
  - !ruby/object:Gem::Version
37
- version: 0.4.1
65
+ version: 0.4.2
38
66
  type: :runtime
39
67
  prerelease: false
40
68
  version_requirements: !ruby/object:Gem::Requirement
@@ -42,7 +70,7 @@ dependencies:
42
70
  requirements:
43
71
  - - ~>
44
72
  - !ruby/object:Gem::Version
45
- version: 0.4.1
73
+ version: 0.4.2
46
74
  - !ruby/object:Gem::Dependency
47
75
  name: sqlite3
48
76
  requirement: !ruby/object:Gem::Requirement
@@ -152,6 +180,7 @@ files:
152
180
  - test/dummy/Rakefile
153
181
  - test/dummy/README.rdoc
154
182
  - test/dummy/script/rails
183
+ - test/fixtures/config/empty.yml
155
184
  - test/fixtures/config/librato.yml
156
185
  - test/fixtures/config/simple.yml
157
186
  - test/integration/cache_test.rb
@@ -179,13 +208,16 @@ required_ruby_version: !ruby/object:Gem::Requirement
179
208
  version: '0'
180
209
  segments:
181
210
  - 0
182
- hash: -1394071796353976924
211
+ hash: -3670832447939112565
183
212
  required_rubygems_version: !ruby/object:Gem::Requirement
184
213
  none: false
185
214
  requirements:
186
- - - ! '>'
215
+ - - ! '>='
187
216
  - !ruby/object:Gem::Version
188
- version: 1.3.1
217
+ version: '0'
218
+ segments:
219
+ - 0
220
+ hash: -3670832447939112565
189
221
  requirements: []
190
222
  rubyforge_project:
191
223
  rubygems_version: 1.8.23
@@ -245,6 +277,7 @@ test_files:
245
277
  - test/dummy/Rakefile
246
278
  - test/dummy/README.rdoc
247
279
  - test/dummy/script/rails
280
+ - test/fixtures/config/empty.yml
248
281
  - test/fixtures/config/librato.yml
249
282
  - test/fixtures/config/simple.yml
250
283
  - test/integration/cache_test.rb
metadata.gz.sig ADDED
@@ -0,0 +1 @@
1
+ sI�����_M�_� ����\3`��9f�LU��c��=${���J��f�3O�V���8����B;�A%|Q�})u)�eh��5�}F��J��[������]<�_j�^K��B��ͅ�u�H-���v[��t���7��k��Y