three-sixty 0.0.6 → 0.0.7

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: 9d4c28a583be1c757f663ede0f284e091590dd57
4
- data.tar.gz: 5b9f8fdf9892d03c171a79513d562181ac85c964
3
+ metadata.gz: 46093f5001048093a0712c6ed9d473845df12bf7
4
+ data.tar.gz: 1a98a57c052bcdaf8cee266c2c2c1edbff6cc60e
5
5
  SHA512:
6
- metadata.gz: efd31c3922a3917057a454c3a8b53e3a4b1862ea516f1e6e21c92b338fec1f46b10ffe4e42803bda4319062082a80527fd73fe2d2a79b7b40d0cd0232d0b9f94
7
- data.tar.gz: d14b987d635b89614c6fa5155a22a18f384f6eacc8e51fdd5f24235ef68a8809818baf85f280bad586391e239c25be112d67ac727670b50e3724fb1e9c3b0a8b
6
+ metadata.gz: 6bd51cd208f2d068415d30088a7c7454ceeb0d1961ad39e34031a9b77c7d6b641188d23d7a847539c6165df6342583099e21a6f2f29815b81e8dff73bad78499
7
+ data.tar.gz: 61f5a9ceafd9c201458e3426dd5e0eedaabfff332bfa6a21b3c36109265aebca68d280a2e436b353ff47ded7c379205a0f215b9caffd70b2ce157dfcb01e46a7
data/.gitignore CHANGED
@@ -2,4 +2,5 @@ documentation/*
2
2
  Gemfile*
3
3
  .bundle/*
4
4
  .ruby*
5
- *.gem
5
+ *.gem
6
+ .DS_Store
@@ -34,11 +34,18 @@ module ThreeSixty
34
34
  uri = URI(generate_url(resource_url, params))
35
35
  @logger.debug "Resquest url #{uri.to_s}"
36
36
  req = Net::HTTP::Post.new(uri, headers = generate_headers)
37
- @logger.debug "Sending headers #{headers}"
38
- res = Net::HTTP.start(uri.host) do |http|
39
- http.request(req)
37
+ retry_counter = 0
38
+ begin
39
+ @logger.debug "Sending headers #{headers}"
40
+ res = Net::HTTP.start(uri.host) do |http|
41
+ http.request(req)
42
+ end
43
+ process_response(res)
44
+ rescue Net::ReadTimeout => e # Some requests can take a while, so just retry a few times
45
+ raise e unless retry_counter < 5
46
+ retry_counter += 1
47
+ retry
40
48
  end
41
- process_response(res)
42
49
  end
43
50
 
44
51
  private
@@ -1,3 +1,3 @@
1
1
  module ThreeSixty
2
- VERSION = "0.0.6"
2
+ VERSION = "0.0.7"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: three-sixty
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Padden
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-19 00:00:00.000000000 Z
11
+ date: 2014-07-02 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Connecting to the 360 api
14
14
  email: