boppers-uptime 0.1.0 → 0.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
2
  SHA1:
3
- metadata.gz: '08b9f90ec4d9408775ebd4347b1413d0c47e19c9'
4
- data.tar.gz: 39a1a32f229f241aa1e840dcd19b76c801729b40
3
+ metadata.gz: 4797774f895bc5f4117a0a0c2385a2d7e7bd982b
4
+ data.tar.gz: 97ef027856f6f2b7dac2a52011f91705121fa88e
5
5
  SHA512:
6
- metadata.gz: 2e24370726d99636da7b5e7f85daef991627dd632b2482effccda16d7e2b81b581927047c34b76ebb5e96695f4643e1e7e3b190edc80e7673576b2bb0d7c280a
7
- data.tar.gz: 8b5f0ba1e1f3ae5cbdd9da2f070ecde12bea7642e2f31e68bd61d88c84a1bbe8b2f20854dceed80ac4f3f0018cadda4e431c8f43e2f4a951d50be094cf492966
6
+ metadata.gz: 48e77379feac150ac59747e5b7cc8ea9a65c252dd44640c8d25510f5a57830318c0e60f988dd184b153ff939c0edd0b33f11f318bcdc9ed700aa95a8c93a7ecf
7
+ data.tar.gz: a4e3ae22fe88499489382982467ba5fc94ab49da283da43244d41fce0e56f05aea8f5b117d9bff0ecf18070f26ccdbbda6c45d0dadaf5ee61a561e1dfd14fb72
data/gems.locked CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- boppers-uptime (0.1.0)
4
+ boppers-uptime (0.1.1)
5
5
  boppers
6
6
  tzinfo
7
7
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Boppers
4
4
  class Uptime
5
- VERSION = "0.1.0"
5
+ VERSION = "0.1.1"
6
6
  end
7
7
  end
@@ -27,9 +27,12 @@ module Boppers
27
27
  end
28
28
 
29
29
  def call
30
- response = HttpClient.get(url)
31
-
32
- succeed = valid_response?(response)
30
+ succeed = begin
31
+ response = HttpClient.get(url, {}, {}, timeout: 1)
32
+ valid_response?(response)
33
+ rescue SocketError, Timeout::Error
34
+ false
35
+ end
33
36
 
34
37
  return succeed! if succeed
35
38
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: boppers-uptime
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nando Vieira