rack-graphite 1.3.0 → 1.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MTVhNThkNTkzMWE0YTMwZDlkOTljM2NjMGZjM2JlMTMxMTBhOTgwOA==
4
+ ODQ0N2I5MjJjMTM5NTMwNmY4NTZjNzhmMTRjZThlZTQ2NzRmYTUxNw==
5
5
  data.tar.gz: !binary |-
6
- ZTFhM2RjYjZhNzNkYzhmNzk2NDU4ZjdiOWJhNDI5MzI1M2Q3NWFkMQ==
6
+ ZjIxZmE5YzcyMzY4NmMwNjJlNzU1NTE3M2EyYzYxMjA2YmVkYmRlYw==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MmUwZTg4MDNjNWY5ODYzM2FhZWUyNTU0NjAzOGIxYTMxMzIxMGVmZjVkMTI3
10
- MWQ4ZDhiN2MxYjNhNTJkMDhmNzU0NmZlM2NjN2UxZTJjYTU0N2JjNWNiNWIx
11
- ZTgwNzI5MjA2OGQxZGY1NzIwMzM1NjQ4YmM3ZWI0NWE0ZGU4OGU=
9
+ N2E4N2ViYjkwMTZjMmM1MjI2MmJhYzI3ZDM5ZDE4MTA1ZWU0ZWIzOTFmMzYw
10
+ ZGVlM2I4YjFjYjI3NDYzOTEzNTUyMGM0Yzg4ZmMyOGY5YjczNDkxZmMxOTA3
11
+ YzNjZjhiZTJjNjkzMWRjZWYyY2Q3N2MxMjMxZDUyYmRlNzlkMGQ=
12
12
  data.tar.gz: !binary |-
13
- MTVhYzQwNjMxOWI3NzhmN2JmMWEzMWU4NTEzMTZmMThhMjRlY2EyZWMwZmM4
14
- MzYxNDg3NjMzNmE3ZWVlM2E1ZjA4ZjRhYjY0YzVkOTlhYmJlYjFmNTI0ODU2
15
- Y2FhZjBmZDFhMTYyYzQ1NzA3M2NkNmYwMGRiNzg5MDIzY2FjYzM=
13
+ ZTc5MDg3YmU0YjMyZjg5YmU1ZTZlYTE0ZWM4MGVjOWU2OWMzN2JkNGNhNzBl
14
+ MzM1ZDhiMDhlMGU4ZmEwMzk4NDc5ZTk5YjA5ODU2MTNkNWJmYTUxODczMzRm
15
+ N2Q2YWU5ZDQzZjAzMzE3MjcwNWE0NGQzOWVlZDg4Y2E0ZDEyYjI=
@@ -19,7 +19,7 @@ module Rack
19
19
  metric = path_to_graphite(method, path)
20
20
 
21
21
  status, headers, body = nil
22
- Lookout::Statsd.instance.timing(metric) do
22
+ Lookout::Statsd.instance.time(metric) do
23
23
  status, headers, body = @app.call(env)
24
24
  end
25
25
  Lookout::Statsd.instance.increment("#{metric}.response.#{status}")
@@ -1,5 +1,5 @@
1
1
  module Rack
2
2
  class Graphite
3
- VERSION = '1.3.0'
3
+ VERSION = '1.4.0'
4
4
  end
5
5
  end
@@ -20,5 +20,5 @@ Gem::Specification.new do |spec|
20
20
 
21
21
  spec.add_development_dependency "bundler", "~> 1.3"
22
22
 
23
- spec.add_dependency 'lookout-statsd', '~> 3.0'
23
+ spec.add_dependency 'lookout-statsd', '~> 3.1'
24
24
  end
@@ -83,8 +83,8 @@ describe Rack::Graphite do
83
83
  subject(:middleware) { described_class.new(app) }
84
84
 
85
85
  before :each do
86
- # Stub out timing by default to and just yield
87
- statsd.stub(:timing).and_yield
86
+ # Stub out time by default to and just yield
87
+ statsd.stub(:time).and_yield
88
88
  statsd.stub(:increment)
89
89
  end
90
90
 
@@ -109,7 +109,7 @@ describe Rack::Graphite do
109
109
  end
110
110
 
111
111
  it 'should invoke a timer' do
112
- statsd.should_receive(:timing)
112
+ statsd.should_receive(:time)
113
113
  middleware.call({})
114
114
  end
115
115
  end
@@ -122,7 +122,7 @@ describe Rack::Graphite do
122
122
 
123
123
  context 'with a root request' do
124
124
  before :each do
125
- statsd.should_receive(:timing).with('requests.get.root').and_yield
125
+ statsd.should_receive(:time).with('requests.get.root').and_yield
126
126
  statsd.should_receive(:increment).with('requests.get.root.response.200')
127
127
  get '/'
128
128
  end
@@ -131,7 +131,7 @@ describe Rack::Graphite do
131
131
 
132
132
  context 'with a request with query params' do
133
133
  before :each do
134
- statsd.should_receive(:timing).with('requests.get.onelevel').and_yield
134
+ statsd.should_receive(:time).with('requests.get.onelevel').and_yield
135
135
  statsd.should_receive(:increment).with('requests.get.onelevel.response.200')
136
136
  get '/onelevel?q=foo'
137
137
  end
@@ -140,7 +140,7 @@ describe Rack::Graphite do
140
140
 
141
141
  context 'with a PUT request' do
142
142
  before :each do
143
- statsd.should_receive(:timing).with('requests.put.onelevel').and_yield
143
+ statsd.should_receive(:time).with('requests.put.onelevel').and_yield
144
144
  statsd.should_receive(:increment).with('requests.put.onelevel.response.200')
145
145
  put '/onelevel'
146
146
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-graphite
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - R. Tyler Croy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-15 00:00:00.000000000 Z
11
+ date: 2016-07-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ~>
32
32
  - !ruby/object:Gem::Version
33
- version: '3.0'
33
+ version: '3.1'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ~>
39
39
  - !ruby/object:Gem::Version
40
- version: '3.0'
40
+ version: '3.1'
41
41
  description: Simple Rack middleware for logging request counts/timing information
42
42
  email:
43
43
  - rtyler.croy@lookout.com