ms_rest 0.7.2 → 0.7.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/README.md +1 -1
- data/lib/ms_rest/http_operation_request.rb +12 -4
- data/lib/ms_rest/version.rb +1 -1
- metadata +8 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9300dab5569a52972502122df91d87bf32cf3e1d
|
4
|
+
data.tar.gz: fee2b777d41042cfef710cac3c8f90ad795cf764
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 31fc088c11a05dbd2a67d83314f64985d6828dbafe4f2000498f5ef9172f2b868a60e574d0a93ceaa73aaf6d9499ee900c743075deeccf5c03c99425c6648d99
|
7
|
+
data.tar.gz: 1781769a506fe083d56c8369ad4a9b975a79d76257cad96b5cffd9e8ff2b316636d89c2f86875777aba9ef0c2bffc54ee057c1158e001957bf600a4c1068ca19
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
##2018.09.25 ms_rest version 0.7.3
|
2
|
+
* [Enhancement] Added code to check for service response and retry if the code is 429 and retry header is provided. Refer [PR #1694](https://github.com/Azure/azure-sdk-for-ruby/pull/1694) for more details.
|
3
|
+
|
1
4
|
##2017.11.10 ms_rest version 0.7.2
|
2
5
|
* [Enhancement] Added code to check & validate the constraints on the model. Refer [PR #1119](https://github.com/Azure/azure-sdk-for-ruby/pull/1119/files) for more details.
|
3
6
|
|
data/README.md
CHANGED
@@ -48,7 +48,7 @@ To start working on the gem the only additional dev dependency is required - rsp
|
|
48
48
|
Reference it in the gemfile and also add this line to your client's gemspec file:
|
49
49
|
|
50
50
|
```ruby
|
51
|
-
spec.add_runtime_dependency 'ms_rest', '~> 0.7.
|
51
|
+
spec.add_runtime_dependency 'ms_rest', '~> 0.7.3'
|
52
52
|
```
|
53
53
|
Don't forget to correct the version.
|
54
54
|
|
@@ -77,14 +77,22 @@ module MsRest
|
|
77
77
|
end
|
78
78
|
end
|
79
79
|
|
80
|
-
|
81
|
-
|
82
|
-
|
80
|
+
loop do
|
81
|
+
@response = @connection.run_request(:"#{method}", build_path, body, {'User-Agent' => user_agent}.merge(headers)) do |req|
|
82
|
+
req.params = req.params.merge(query_params.reject{|_, v| v.nil?}) unless query_params.nil?
|
83
|
+
yield(req) if block_given?
|
84
|
+
end
|
85
|
+
|
86
|
+
break if ((@response.status != 429) || (@response.status == 429 && @response.headers['retry-after'].nil?))
|
87
|
+
|
88
|
+
if(@response.status == 429 && !@response.headers['retry-after'].nil?)
|
89
|
+
sleep(@response.headers['retry-after'].to_i)
|
90
|
+
end
|
83
91
|
end
|
92
|
+
@response
|
84
93
|
end
|
85
94
|
end
|
86
95
|
|
87
|
-
|
88
96
|
# Creates a path from the path template and the path_params and skip_encoding_path_params
|
89
97
|
# @return [URI] body the HTTP response body.
|
90
98
|
def build_path
|
data/lib/ms_rest/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ms_rest
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Microsoft Corporation
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-09-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -124,7 +124,12 @@ files:
|
|
124
124
|
homepage: https://aka.ms/ms_rest
|
125
125
|
licenses:
|
126
126
|
- MIT
|
127
|
-
metadata:
|
127
|
+
metadata:
|
128
|
+
bug_tracker_uri: https://github.com/Azure/azure-sdk-for-ruby/issues
|
129
|
+
changelog_uri: https://github.com/Azure/azure-sdk-for-ruby/blob/master/runtime/ms_rest/CHANGELOG.md
|
130
|
+
documentation_uri: https://azure.microsoft.com/en-us/develop/ruby/
|
131
|
+
homepage_uri: https://aka.ms/azure-sdk-for-ruby
|
132
|
+
source_code_uri: https://github.com/Azure/azure-sdk-for-ruby/tree/ms_rest-v0.7.3
|
128
133
|
post_install_message:
|
129
134
|
rdoc_options: []
|
130
135
|
require_paths:
|