breakers 0.2.1 → 0.2.2

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: 35c7aacf61c91cf32f46b61946acb6f80d0b00fc
4
- data.tar.gz: 4d62beb0e55e286b22ae035f2ac3a8f390a271fd
3
+ metadata.gz: 9e6817087ef7b241395a0788e84a0ee14cfb476f
4
+ data.tar.gz: 95130c9e75c4915a1b6d6fd88bcc8ee8ae7e1564
5
5
  SHA512:
6
- metadata.gz: 2cc042397050ea304a6632a7f758e9fe2f3efdabc48843759366f6f953a50762ecd432be06846d211b2e537b7e283730772f021febc866d85447166e32444323
7
- data.tar.gz: 9358d0bbf12c1b5b378ecaa2b94584e775887e746958ef0405d176daf5a207ba780a108428ab7f49c6fa92eebe6174e90ad6668004b085de0b473fc4a6f90c77
6
+ metadata.gz: df1d03686061dea6bc19d266463d7d884e5d2610740b6381cdd25c90e48beace78d59f9f7590c275b696d7068d2156e04dd7b5ee6b5bb326d51150b966a27c96
7
+ data.tar.gz: 44c580e0f38c489e474fbe8c88ab79a1b2ad0d259973964765c296f0a9e73b08519248a6c134d77e3462e8c1e5fa03060cb6c04288a6ce9abbb6ab802fc8cec2
@@ -49,7 +49,9 @@ module Breakers
49
49
  end
50
50
 
51
51
  def handle_request(service:, request_env:, current_outage: nil)
52
+ start_time = Time.now
52
53
  return @app.call(request_env).on_complete do |response_env|
54
+ response_env[:duration] = Time.now - start_time
53
55
  if response_env.status >= 500
54
56
  handle_error(
55
57
  service: service,
@@ -1,3 +1,3 @@
1
1
  module Breakers
2
- VERSION = '0.2.1'.freeze
2
+ VERSION = '0.2.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: breakers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aubrey Holland
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-10-26 00:00:00.000000000 Z
11
+ date: 2016-10-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday