librato-rack 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 7b2e81e09050e4d9b1f448806ec43c19314de09a
4
- data.tar.gz: 4d6a014870df60b95a7fedc4efda0a5a96bf3a50
2
+ SHA256:
3
+ metadata.gz: 166d12211f03918ae932f69cef410ab25dab8c81559418f7bfbcb60d6ba518b6
4
+ data.tar.gz: fe3b81c8d79e7583e4f2ab49e6e5c8eaea52ec0190b5d5f5734581bd06c6d85d
5
5
  SHA512:
6
- metadata.gz: cd329d855d6dcf6036e3f685c9e7ba29276ef731415de1674ac77df9a3dc91e05afd606917f36da2a0d1b1ab38d580af738af94c528d6287115e618a0bf914af
7
- data.tar.gz: 42bf488009d6868df5227720d320dd9c6b0bd3ab8de15db4ee28f5e5fed7a2c1efd9781cf1463483cbfe0cb11ded77cf9268057b6df1131986f40549cbf99cbf
6
+ metadata.gz: 901388b2a16efea6d162189a96102f52e84c4904909f50c53ce024698dee51618bb5266c67b0af740492bee13028fe676849660758e8116cd2e4b0e92e4d2ad5
7
+ data.tar.gz: 3118d9c1cd7bf4a89a89454120a4149b821466f72c682871ce97d2b83082909fed5e977bc48fa3d6b6bf47d746958f56606311fa85cbd85999fea1c7ca2cad4b
data/lib/librato/rack.rb CHANGED
@@ -55,9 +55,9 @@ module Librato
55
55
 
56
56
  RECORD_RACK_METHOD_BODY = <<-'EOS'
57
57
  group.group 'method' do |m|
58
- http_method.downcase!
59
- m.increment http_method
60
- m.timing "#{http_method}.time", duration
58
+ method = http_method.downcase
59
+ m.increment method
60
+ m.timing "#{method}.time", duration
61
61
  end
62
62
  EOS
63
63
 
@@ -1,5 +1,5 @@
1
1
  module Librato
2
2
  class Rack
3
- VERSION = "1.1.0"
3
+ VERSION = "1.1.1"
4
4
  end
5
5
  end
@@ -19,10 +19,13 @@ class QueueWaitTest < Minitest::Test
19
19
  def test_milliseconds
20
20
  get '/milli'
21
21
 
22
+ # give jruby a bit more time since it can be slow
23
+ delta = defined?(JRUBY_VERSION) ? 6 : 4
24
+
22
25
  # puts "milli: #{aggregate["rack.request.queue.time"].inspect}"
23
26
  assert_equal 1, aggregate["rack.request.queue.time"][:count],
24
27
  'should track total queue time'
25
- assert_in_delta 5, aggregate["rack.request.queue.time"][:sum], 4
28
+ assert_in_delta 5, aggregate["rack.request.queue.time"][:sum], delta
26
29
  end
27
30
 
28
31
  def test_microseconds
@@ -37,10 +40,13 @@ class QueueWaitTest < Minitest::Test
37
40
  def test_queue_start
38
41
  get '/queue_start'
39
42
 
43
+ # give jruby a bit more time since it can be slow
44
+ delta = defined?(JRUBY_VERSION) ? 6 : 4
45
+
40
46
  # puts "micro: #{aggregate["rack.request.queue.time"].inspect}"
41
47
  assert_equal 1, aggregate["rack.request.queue.time"][:count],
42
48
  'should track total queue time'
43
- assert_in_delta 15, aggregate["rack.request.queue.time"][:sum], 4
49
+ assert_in_delta 15, aggregate["rack.request.queue.time"][:sum], delta
44
50
  end
45
51
 
46
52
  def test_with_t
@@ -57,6 +57,13 @@ class RequestTest < Minitest::Test
57
57
  assert_equal 1, aggregate['rack.request.method.post.time'][:count]
58
58
  end
59
59
 
60
+ def test_request_method_not_mutated
61
+ get '/', {}, {'REQUEST_METHOD' => "GET".freeze}
62
+
63
+ assert_equal 1, counters['rack.request.method.get']
64
+ assert_equal 1, aggregate['rack.request.method.get.time'][:count]
65
+ end
66
+
60
67
  def test_track_exceptions
61
68
  begin
62
69
  get '/exception'
metadata CHANGED
@@ -1,35 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: librato-rack
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Sanders
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain:
11
- - |
12
- -----BEGIN CERTIFICATE-----
13
- MIIDLjCCAhagAwIBAgIBADANBgkqhkiG9w0B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XVghM2qsonAwI/rTNmFJN9kQn6nP9+f1Uf/qZFNcjn4L
30
- 9bg=
31
- -----END CERTIFICATE-----
32
- date: 2017-01-11 00:00:00.000000000 Z
11
+ - certs/librato-public.pem
12
+ date: 2018-08-07 00:00:00.000000000 Z
33
13
  dependencies:
34
14
  - !ruby/object:Gem::Dependency
35
15
  name: librato-metrics
@@ -77,7 +57,6 @@ description: Rack middleware to report key app statistics and custom instrumenta
77
57
  to the Librato Metrics service.
78
58
  email:
79
59
  - matt@librato.com
80
- - ruby@librato.com
81
60
  executables: []
82
61
  extensions: []
83
62
  extra_rdoc_files: []
@@ -126,7 +105,7 @@ files:
126
105
  - test/unit/rack/worker_test.rb
127
106
  homepage: https://github.com/librato/librato-rack
128
107
  licenses:
129
- - BSD-3-Clause
108
+ - BSD 3-clause
130
109
  metadata: {}
131
110
  post_install_message:
132
111
  rdoc_options: []
@@ -144,31 +123,31 @@ required_rubygems_version: !ruby/object:Gem::Requirement
144
123
  version: '0'
145
124
  requirements: []
146
125
  rubyforge_project:
147
- rubygems_version: 2.6.8
126
+ rubygems_version: 2.7.6
148
127
  signing_key:
149
128
  specification_version: 4
150
129
  summary: Use Librato Metrics with your rack application
151
130
  test_files:
152
- - test/apps/basic.ru
153
- - test/apps/custom.ru
154
- - test/apps/custom_suites.ru
155
- - test/apps/no_stats.ru
156
- - test/apps/queue_wait.ru
157
- - test/integration/custom_test.rb
158
- - test/integration/no_stats_test.rb
159
- - test/integration/no_suites_test.rb
160
- - test/integration/queue_wait_test.rb
161
- - test/integration/request_test.rb
162
- - test/integration/suites_test.rb
163
- - test/remote/tracker_test.rb
164
- - test/support/environment_helpers.rb
165
- - test/test_helper.rb
166
- - test/unit/collector/aggregator_test.rb
131
+ - test/unit/collector_test.rb
167
132
  - test/unit/collector/counter_cache_test.rb
168
133
  - test/unit/collector/group_test.rb
169
- - test/unit/collector_test.rb
134
+ - test/unit/collector/aggregator_test.rb
170
135
  - test/unit/rack/configuration/suites_test.rb
171
- - test/unit/rack/configuration_test.rb
172
136
  - test/unit/rack/logger_test.rb
173
137
  - test/unit/rack/tracker_test.rb
138
+ - test/unit/rack/configuration_test.rb
174
139
  - test/unit/rack/worker_test.rb
140
+ - test/integration/no_stats_test.rb
141
+ - test/integration/queue_wait_test.rb
142
+ - test/integration/request_test.rb
143
+ - test/integration/custom_test.rb
144
+ - test/integration/no_suites_test.rb
145
+ - test/integration/suites_test.rb
146
+ - test/support/environment_helpers.rb
147
+ - test/test_helper.rb
148
+ - test/apps/queue_wait.ru
149
+ - test/apps/custom_suites.ru
150
+ - test/apps/custom.ru
151
+ - test/apps/no_stats.ru
152
+ - test/apps/basic.ru
153
+ - test/remote/tracker_test.rb
checksums.yaml.gz.sig DELETED
Binary file
data.tar.gz.sig DELETED
Binary file
metadata.gz.sig DELETED
Binary file