vitals 0.6.0 → 0.7.0

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
2
  SHA1:
3
- metadata.gz: e9e5ba3c92282f21ad9d99202b745fac43ba7ef4
4
- data.tar.gz: d33d618d83901d8bf6cc19f708b865acc977269a
3
+ metadata.gz: 3812a6ac57aece8615d8ed54806b2db5c587d2fe
4
+ data.tar.gz: d1792d8265dc2b13d5b4f3bd4a228912e789907f
5
5
  SHA512:
6
- metadata.gz: 231707f0c9836419a53606ac64fce4f56f8454835e4b21451d0bb2389676fd5671d6d703ce5fbbcf2be31db94062925f8bf596355a5139508b6d09df715f003f
7
- data.tar.gz: 20b6e2a3a88fa5b2d27b9bd7d808ad014b18a576c2a8a34b69e679848f0a88ed9d47bf2faeb3345835fd7398dc718dd032c678f020a9f3fdcd33d8e520b5ec55
6
+ metadata.gz: 2d699b17fe6da7822629646bbcbe1afd34d95d32244fe5d61fbff09ac9e6ed0976308583b6cd8d9824cd108c20246e36d3e412d8f266079e9c551aa626e06267
7
+ data.tar.gz: ae6cef4f146d70e8bfcb636482d63762e19b09d61241cbea4d13ddad08f323d81f0cec6974db262890ba698ed470da050a794816ee1634fea31ffc71e10622b2
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- vitals (0.5.0)
4
+ vitals (0.7.0)
5
5
  statsd-ruby (~> 1.3.0)
6
6
 
7
7
  GEM
@@ -82,7 +82,7 @@ GEM
82
82
  notiffany (0.0.8)
83
83
  nenv (~> 0.1)
84
84
  shellany (~> 0.0)
85
- parser (2.3.0.6)
85
+ parser (2.3.0.7)
86
86
  ast (~> 2.2)
87
87
  powerpack (0.1.1)
88
88
  pry (0.10.3)
@@ -104,8 +104,8 @@ GEM
104
104
  rb-inotify (0.9.7)
105
105
  ffi (>= 0.5.0)
106
106
  rr (1.1.2)
107
- rubocop (0.38.0)
108
- parser (>= 2.3.0.6, < 3.0)
107
+ rubocop (0.39.0)
108
+ parser (>= 2.3.0.7, < 3.0)
109
109
  powerpack (~> 0.1)
110
110
  rainbow (>= 1.99.1, < 3.0)
111
111
  ruby-progressbar (~> 1.7)
@@ -131,7 +131,7 @@ GEM
131
131
  tins (1.6.0)
132
132
  tzinfo (1.2.2)
133
133
  thread_safe (~> 0.1)
134
- unicode-display_width (1.0.2)
134
+ unicode-display_width (1.0.3)
135
135
  virtus (1.0.5)
136
136
  axiom-types (~> 0.1)
137
137
  coercible (~> 1.0)
@@ -3,6 +3,7 @@ module Vitals::Integrations::Rack
3
3
  REQUEST_METHOD = 'REQUEST_METHOD'.freeze
4
4
 
5
5
  RACK_PATH_INFO = 'PATH_INFO'.freeze
6
+ RACK_ROUTER_INFO = 'rack.routing_args'.freeze
6
7
  SINATRA_PATH_INFO = 'sinatra.route'.freeze
7
8
  GRAPE_PATH_INFO = 'api.endpoint'.freeze
8
9
  RAILS_PATH_INFO = 'action_controller.instance'.freeze
@@ -40,7 +41,16 @@ module Vitals::Integrations::Rack
40
41
  end
41
42
 
42
43
  def self.grape_path(env)
43
- Vitals::Utils.grape_path(env[GRAPE_PATH_INFO].route)
44
+ route = if env[RACK_ROUTER_INFO]
45
+ # grape 0.11 route bug workaround with http_basic.
46
+ # when unauthenticated, GRAPE_PATH_INFO route has a nil env. this one
47
+ # here doesn't:
48
+ env[RACK_ROUTER_INFO][:route_info]
49
+ else
50
+ # grape > 0.11
51
+ env[GRAPE_PATH_INFO].route
52
+ end
53
+ Vitals::Utils.grape_path(route)
44
54
  end
45
55
 
46
56
  def self.rails_path(env)
@@ -1,3 +1,3 @@
1
1
  module Vitals
2
- VERSION = "0.6.0"
2
+ VERSION = "0.7.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vitals
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dotan Nahum
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-03 00:00:00.000000000 Z
11
+ date: 2016-04-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: statsd-ruby