gapic-common 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +21 -0
- data/lib/gapic/call_options.rb +3 -1
- data/lib/gapic/call_options/retry_policy.rb +42 -2
- data/lib/gapic/common/version.rb +1 -1
- data/lib/gapic/config.rb +1 -1
- data/lib/gapic/grpc/service_stub.rb +3 -2
- data/lib/gapic/grpc/service_stub/rpc_call.rb +1 -3
- data/lib/gapic/grpc/status_details.rb +5 -7
- data/lib/gapic/paged_enumerable.rb +5 -5
- data/lib/gapic/protobuf.rb +1 -1
- data/lib/gapic/rest.rb +27 -0
- data/lib/gapic/rest/client_stub.rb +126 -0
- data/lib/gapic/rest/error.rb +73 -0
- data/lib/gapic/rest/faraday_middleware.rb +45 -0
- metadata +47 -23
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9d5a60dd75b6fe30ba3654e69aa129b07c7a2159dff65134c9fd67ed8a598d70
|
4
|
+
data.tar.gz: c8cd0851a4f8f04dab553bf55bda12851cfdec0eaa9e1f6859c0e1a93f2555c7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e12310e5446b7dffa8a6c5cc3df4b0181414ae2e3118199d45b4cf2e54d1b61a7d72561634402ae319f66a0bcfa3786be67aaf4c8fb3e4a6e839ebdf27a58e64
|
7
|
+
data.tar.gz: 46752b4a1dee19463222b187de90071cf1a569ac83a8eabc13373f2d35460eb6a6f0ee681fbeab7165cebed0bf730d08cfe48da326d61c5fb5ef702fd6b020d1
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,26 @@
|
|
1
1
|
# Release History
|
2
2
|
|
3
|
+
### 0.4.0 / 2021-02-23
|
4
|
+
|
5
|
+
* Support for the REST calls via the Gapic::Rest::ClientStub and other classes in Gapic::Rest
|
6
|
+
REST support is still being developed. Notably the full retries handling is not implemented yet.
|
7
|
+
|
8
|
+
### 0.3.4 / 2020-08-07
|
9
|
+
|
10
|
+
* Support the :this_channel_is_insecure gRPC pseudo-credential, used by tests and emulators.
|
11
|
+
|
12
|
+
### 0.3.3 / 2020-08-05
|
13
|
+
|
14
|
+
* Retry configs properly handle error name strings.
|
15
|
+
|
16
|
+
### 0.3.2 / 2020-07-30
|
17
|
+
|
18
|
+
* Alias PagedEnumerable#next_page to PagedEnumerable#next_page!
|
19
|
+
|
20
|
+
### 0.3.1 / 2020-06-19
|
21
|
+
|
22
|
+
* Fix file permissions
|
23
|
+
|
3
24
|
### 0.3.0 / 2020-06-18
|
4
25
|
|
5
26
|
* Update the dependency on google-protobuf to 3.12.2
|
data/lib/gapic/call_options.rb
CHANGED
@@ -29,7 +29,7 @@ module Gapic
|
|
29
29
|
# @param max_delay [Numeric] client-side timeout
|
30
30
|
#
|
31
31
|
def initialize retry_codes: nil, initial_delay: nil, multiplier: nil, max_delay: nil
|
32
|
-
@retry_codes = retry_codes
|
32
|
+
@retry_codes = convert_codes retry_codes
|
33
33
|
@initial_delay = initial_delay
|
34
34
|
@multiplier = multiplier
|
35
35
|
@max_delay = max_delay
|
@@ -77,7 +77,7 @@ module Gapic
|
|
77
77
|
def apply_defaults retry_policy
|
78
78
|
return unless retry_policy.is_a? Hash
|
79
79
|
|
80
|
-
@retry_codes ||= retry_policy[:retry_codes]
|
80
|
+
@retry_codes ||= convert_codes retry_policy[:retry_codes]
|
81
81
|
@initial_delay ||= retry_policy[:initial_delay]
|
82
82
|
@multiplier ||= retry_policy[:multiplier]
|
83
83
|
@max_delay ||= retry_policy[:max_delay]
|
@@ -85,6 +85,34 @@ module Gapic
|
|
85
85
|
self
|
86
86
|
end
|
87
87
|
|
88
|
+
# @private
|
89
|
+
# See https://grpc.github.io/grpc/core/md_doc_statuscodes.html for a
|
90
|
+
# list of error codes.
|
91
|
+
ERROR_CODE_MAPPING = [
|
92
|
+
"OK",
|
93
|
+
"CANCELLED",
|
94
|
+
"UNKNOWN",
|
95
|
+
"INVALID_ARGUMENT",
|
96
|
+
"DEADLINE_EXCEEDED",
|
97
|
+
"NOT_FOUND",
|
98
|
+
"ALREADY_EXISTS",
|
99
|
+
"PERMISSION_DENIED",
|
100
|
+
"RESOURCE_EXHAUSTED",
|
101
|
+
"FAILED_PRECONDITION",
|
102
|
+
"ABORTED",
|
103
|
+
"OUT_OF_RANGE",
|
104
|
+
"UNIMPLEMENTED",
|
105
|
+
"INTERNAL",
|
106
|
+
"UNAVAILABLE",
|
107
|
+
"DATA_LOSS",
|
108
|
+
"UNAUTHENTICATED"
|
109
|
+
].freeze
|
110
|
+
|
111
|
+
# @private
|
112
|
+
ERROR_STRING_MAPPING = ERROR_CODE_MAPPING.each_with_index.each_with_object({}) do |(str, num), hash|
|
113
|
+
hash[str] = num
|
114
|
+
end.freeze
|
115
|
+
|
88
116
|
private
|
89
117
|
|
90
118
|
def retry? error
|
@@ -96,6 +124,18 @@ module Gapic
|
|
96
124
|
Kernel.sleep delay
|
97
125
|
end
|
98
126
|
|
127
|
+
def convert_codes input_codes
|
128
|
+
return nil if input_codes.nil?
|
129
|
+
Array(input_codes).map do |obj|
|
130
|
+
case obj
|
131
|
+
when String
|
132
|
+
ERROR_STRING_MAPPING[obj]
|
133
|
+
when Integer
|
134
|
+
obj
|
135
|
+
end
|
136
|
+
end.compact
|
137
|
+
end
|
138
|
+
|
99
139
|
##
|
100
140
|
# Calculate and set the next delay value.
|
101
141
|
def increment_delay!
|
data/lib/gapic/common/version.rb
CHANGED
data/lib/gapic/config.rb
CHANGED
@@ -58,10 +58,11 @@ module Gapic
|
|
58
58
|
channel_args = Hash channel_args
|
59
59
|
interceptors = Array interceptors
|
60
60
|
|
61
|
-
@grpc_stub =
|
61
|
+
@grpc_stub = case credentials
|
62
|
+
when GRPC::Core::Channel
|
62
63
|
grpc_stub_class.new endpoint, nil, channel_override: credentials,
|
63
64
|
interceptors: interceptors
|
64
|
-
|
65
|
+
when GRPC::Core::ChannelCredentials, Symbol
|
65
66
|
grpc_stub_class.new endpoint, credentials, channel_args: channel_args,
|
66
67
|
interceptors: interceptors
|
67
68
|
else
|
@@ -122,9 +122,7 @@ module Gapic
|
|
122
122
|
yield response, operation if block_given?
|
123
123
|
response
|
124
124
|
rescue StandardError => e
|
125
|
-
if check_retry?
|
126
|
-
retry if options.retry_policy.call e
|
127
|
-
end
|
125
|
+
retry if check_retry?(deadline) && options.retry_policy.call(e)
|
128
126
|
|
129
127
|
raise e
|
130
128
|
end
|
@@ -27,13 +27,11 @@ module GRPC
|
|
27
27
|
return nil.to_a if rpc_status.nil?
|
28
28
|
|
29
29
|
rpc_status.details.map do |detail|
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
detail
|
36
|
-
end
|
30
|
+
detail_type = Google::Protobuf::DescriptorPool.generated_pool.lookup detail.type_name
|
31
|
+
detail = detail.unpack detail_type.msgclass if detail_type
|
32
|
+
detail
|
33
|
+
rescue Google::Protobuf::ParseError
|
34
|
+
detail
|
37
35
|
end
|
38
36
|
end
|
39
37
|
end
|
@@ -80,13 +80,11 @@ module Gapic
|
|
80
80
|
#
|
81
81
|
# @raise [RuntimeError] if it's not started yet.
|
82
82
|
#
|
83
|
-
def each
|
83
|
+
def each &block
|
84
84
|
return enum_for :each unless block_given?
|
85
85
|
|
86
86
|
each_page do |page|
|
87
|
-
page.each
|
88
|
-
yield obj
|
89
|
-
end
|
87
|
+
page.each(&block)
|
90
88
|
end
|
91
89
|
end
|
92
90
|
|
@@ -132,6 +130,7 @@ module Gapic
|
|
132
130
|
end
|
133
131
|
@page
|
134
132
|
end
|
133
|
+
alias next_page next_page!
|
135
134
|
|
136
135
|
##
|
137
136
|
# The page token to be used for the next RPC call.
|
@@ -200,7 +199,8 @@ module Gapic
|
|
200
199
|
# @return [GRPC::ActiveCall::Operation] the RPC operation for the page.
|
201
200
|
class Page
|
202
201
|
include Enumerable
|
203
|
-
attr_reader :response
|
202
|
+
attr_reader :response
|
203
|
+
attr_reader :operation
|
204
204
|
|
205
205
|
##
|
206
206
|
# @private
|
data/lib/gapic/protobuf.rb
CHANGED
@@ -96,7 +96,7 @@ module Gapic
|
|
96
96
|
#
|
97
97
|
# @return [Array<Object>] The coerced version of the given values.
|
98
98
|
def self.coerce_array array, field_descriptor
|
99
|
-
raise ArgumentError, "Value
|
99
|
+
raise ArgumentError, "Value #{array} must be an array" unless array.is_a? Array
|
100
100
|
array.map do |val|
|
101
101
|
coerce_value val, field_descriptor
|
102
102
|
end
|
data/lib/gapic/rest.rb
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
# Copyright 2021 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
##
|
16
|
+
# Rest GAPIC features are still under development.
|
17
|
+
#
|
18
|
+
|
19
|
+
require "faraday"
|
20
|
+
require "gapic/call_options"
|
21
|
+
require "gapic/common/version"
|
22
|
+
require "gapic/headers"
|
23
|
+
require "gapic/protobuf"
|
24
|
+
require "gapic/rest/client_stub"
|
25
|
+
require "gapic/rest/error"
|
26
|
+
require "gapic/rest/faraday_middleware"
|
27
|
+
require "json"
|
@@ -0,0 +1,126 @@
|
|
1
|
+
# Copyright 2021 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require "googleauth"
|
16
|
+
require "gapic/rest/faraday_middleware"
|
17
|
+
|
18
|
+
module Gapic
|
19
|
+
module Rest
|
20
|
+
##
|
21
|
+
# A class for making REST calls through Faraday
|
22
|
+
# ClientStub's responsibilities:
|
23
|
+
# - wrap Faraday methods with a bounded explicit interface
|
24
|
+
# - store service endpoint and create full url for the request
|
25
|
+
# - store credentials and add auth information to the request
|
26
|
+
#
|
27
|
+
class ClientStub
|
28
|
+
##
|
29
|
+
# Initializes with an endpoint and credentials
|
30
|
+
# @param endpoint [String] an endpoint for the service that this stub will send requests to
|
31
|
+
# @param credentials [Google::Auth::Credentials]
|
32
|
+
# Credentials to send with calls in form of a googleauth credentials object.
|
33
|
+
# (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
|
34
|
+
#
|
35
|
+
# @yield [Faraday::Connection]
|
36
|
+
#
|
37
|
+
def initialize endpoint:, credentials:
|
38
|
+
@endpoint = endpoint
|
39
|
+
@endpoint = "https://#{endpoint}" unless /^https?:/.match? endpoint
|
40
|
+
@endpoint.sub! %r{/$}, ""
|
41
|
+
|
42
|
+
@credentials = credentials
|
43
|
+
|
44
|
+
@connection = Faraday.new url: @endpoint do |conn|
|
45
|
+
conn.headers = { "Content-Type" => "application/json" }
|
46
|
+
conn.request :google_authorization, @credentials
|
47
|
+
conn.request :retry
|
48
|
+
conn.response :raise_error
|
49
|
+
conn.adapter :net_http
|
50
|
+
end
|
51
|
+
|
52
|
+
yield @connection if block_given?
|
53
|
+
end
|
54
|
+
|
55
|
+
##
|
56
|
+
# Makes a GET request
|
57
|
+
#
|
58
|
+
# @param uri [String] uri to send this request to
|
59
|
+
# @param params [Hash] query string parameters for the request
|
60
|
+
# @param options [::Gapic::CallOptions] gapic options to be applied to the REST call.
|
61
|
+
# Currently only timeout and headers are supported.
|
62
|
+
# @return [Faraday::Response]
|
63
|
+
def make_get_request uri:, params: {}, options: {}
|
64
|
+
make_http_request :get, uri: uri, body: nil, params: params, options: options
|
65
|
+
end
|
66
|
+
|
67
|
+
##
|
68
|
+
# Makes a DELETE request
|
69
|
+
#
|
70
|
+
# @param uri [String] uri to send this request to
|
71
|
+
# @param params [Hash] query string parameters for the request
|
72
|
+
# @param options [::Gapic::CallOptions] gapic options to be applied to the REST call.
|
73
|
+
# Currently only timeout and headers are supported.
|
74
|
+
# @return [Faraday::Response]
|
75
|
+
def make_delete_request uri:, params: {}, options: {}
|
76
|
+
make_http_request :delete, uri: uri, body: nil, params: params, options: options
|
77
|
+
end
|
78
|
+
|
79
|
+
##
|
80
|
+
# Makes a POST request
|
81
|
+
#
|
82
|
+
# @param uri [String] uri to send this request to
|
83
|
+
# @param body [String] a body to send with the request, nil for requests without a body
|
84
|
+
# @param params [Hash] query string parameters for the request
|
85
|
+
# @param options [::Gapic::CallOptions] gapic options to be applied to the REST call.
|
86
|
+
# Currently only timeout and headers are supported.
|
87
|
+
# @return [Faraday::Response]
|
88
|
+
def make_post_request uri:, body:, params: {}, options: {}
|
89
|
+
make_http_request :post, uri: uri, body: body, params: params, options: options
|
90
|
+
end
|
91
|
+
|
92
|
+
##
|
93
|
+
# Makes a PATCH request
|
94
|
+
#
|
95
|
+
# @param uri [String] uri to send this request to
|
96
|
+
# @param body [String] a body to send with the request, nil for requests without a body
|
97
|
+
# @param params [Hash] query string parameters for the request
|
98
|
+
# @param options [::Gapic::CallOptions] gapic options to be applied to the REST call.
|
99
|
+
# Currently only timeout and headers are supported.
|
100
|
+
# @return [Faraday::Response]
|
101
|
+
def make_patch_request uri:, body:, params: {}, options: {}
|
102
|
+
make_http_request :patch, uri: uri, body: body, params: params, options: options
|
103
|
+
end
|
104
|
+
|
105
|
+
protected
|
106
|
+
|
107
|
+
##
|
108
|
+
# Sends a http request via Faraday
|
109
|
+
# @param verb [Symbol] http verb
|
110
|
+
# @param uri [String] uri to send this request to
|
111
|
+
# @param body [String, nil] a body to send with the request, nil for requests without a body
|
112
|
+
# @param params [Hash] query string parameters for the request
|
113
|
+
# @param options [::Gapic::CallOptions] gapic options to be applied to the REST call.
|
114
|
+
# Currently only timeout and headers are supported.
|
115
|
+
# @return [Faraday::Response]
|
116
|
+
def make_http_request verb, uri:, body:, params:, options:
|
117
|
+
@connection.send verb, uri do |req|
|
118
|
+
req.params = params if params.any?
|
119
|
+
req.body = body unless body.nil?
|
120
|
+
req.headers = req.headers.merge options.metadata
|
121
|
+
req.options.timeout = options.timeout if options.timeout&.positive?
|
122
|
+
end
|
123
|
+
end
|
124
|
+
end
|
125
|
+
end
|
126
|
+
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
# Copyright 2021 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require "json"
|
16
|
+
|
17
|
+
module Gapic
|
18
|
+
module Rest
|
19
|
+
# Gapic REST exception class
|
20
|
+
class Error < StandardError
|
21
|
+
# @return [Integer] the http status code for the error
|
22
|
+
attr_reader :status_code
|
23
|
+
|
24
|
+
##
|
25
|
+
# @param message [String, nil] error message
|
26
|
+
# @param status_code [Integer, nil] HTTP status code of this error
|
27
|
+
#
|
28
|
+
def initialize message, status_code
|
29
|
+
@status_code = status_code
|
30
|
+
super message
|
31
|
+
end
|
32
|
+
|
33
|
+
class << self
|
34
|
+
##
|
35
|
+
# This creates a new error message wrapping the Faraday's one. Additionally
|
36
|
+
# it tries to parse and set a detailed message and an error code from
|
37
|
+
# from the Google Cloud's response body
|
38
|
+
#
|
39
|
+
def wrap_faraday_error err
|
40
|
+
message = err.message
|
41
|
+
status_code = err.response_status
|
42
|
+
|
43
|
+
if err.response_body
|
44
|
+
msg, code = try_parse_from_body err.response_body
|
45
|
+
message = "An error has occurred when making a REST request: #{msg}" unless msg.nil?
|
46
|
+
status_code = code unless code.nil?
|
47
|
+
end
|
48
|
+
|
49
|
+
Gapic::Rest::Error.new message, status_code
|
50
|
+
end
|
51
|
+
|
52
|
+
private
|
53
|
+
|
54
|
+
##
|
55
|
+
# Tries to get the error information from the JSON bodies
|
56
|
+
#
|
57
|
+
# @param body_str [String]
|
58
|
+
# @return [Array(String, String)]
|
59
|
+
def try_parse_from_body body_str
|
60
|
+
body = JSON.parse body_str
|
61
|
+
return [nil, nil] unless body && body["error"].is_a?(Hash)
|
62
|
+
|
63
|
+
message = body["error"]["message"]
|
64
|
+
code = body["error"]["code"]
|
65
|
+
|
66
|
+
[message, code]
|
67
|
+
rescue JSON::ParserError
|
68
|
+
[nil, nil]
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
@@ -0,0 +1,45 @@
|
|
1
|
+
# Copyright 2021 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
require "faraday"
|
15
|
+
|
16
|
+
module Gapic
|
17
|
+
module Rest
|
18
|
+
# Registers the middleware with Faraday
|
19
|
+
module FaradayMiddleware
|
20
|
+
##
|
21
|
+
# Request middleware that constructs the Authorization HTTP header
|
22
|
+
# using ::Google::Auth::Credentials
|
23
|
+
#
|
24
|
+
class GoogleAuthorization < Faraday::Middleware
|
25
|
+
##
|
26
|
+
# @param app [#call]
|
27
|
+
# @param credentials [::Google::Auth::Credentials]
|
28
|
+
def initialize app, credentials
|
29
|
+
@credentials = credentials
|
30
|
+
super app
|
31
|
+
end
|
32
|
+
|
33
|
+
# @param env [Faraday::Env]
|
34
|
+
def call env
|
35
|
+
auth_hash = @credentials.client.apply({})
|
36
|
+
env.request_headers["Authorization"] = auth_hash[:authorization]
|
37
|
+
|
38
|
+
@app.call env
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
Faraday::Request.register_middleware google_authorization: -> { GoogleAuthorization }
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
metadata
CHANGED
@@ -1,42 +1,36 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gapic-common
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google API Authors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: faraday
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '3
|
20
|
-
- - ">="
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: 3.12.2
|
19
|
+
version: '1.3'
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
26
23
|
requirements:
|
27
24
|
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
|
-
version: '3
|
30
|
-
- - ">="
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: 3.12.2
|
26
|
+
version: '1.3'
|
33
27
|
- !ruby/object:Gem::Dependency
|
34
28
|
name: googleapis-common-protos
|
35
29
|
requirement: !ruby/object:Gem::Requirement
|
36
30
|
requirements:
|
37
31
|
- - ">="
|
38
32
|
- !ruby/object:Gem::Version
|
39
|
-
version: 1.3.
|
33
|
+
version: 1.3.11
|
40
34
|
- - "<"
|
41
35
|
- !ruby/object:Gem::Version
|
42
36
|
version: '2.0'
|
@@ -46,7 +40,7 @@ dependencies:
|
|
46
40
|
requirements:
|
47
41
|
- - ">="
|
48
42
|
- !ruby/object:Gem::Version
|
49
|
-
version: 1.3.
|
43
|
+
version: 1.3.11
|
50
44
|
- - "<"
|
51
45
|
- !ruby/object:Gem::Version
|
52
46
|
version: '2.0'
|
@@ -56,7 +50,7 @@ dependencies:
|
|
56
50
|
requirements:
|
57
51
|
- - ">="
|
58
52
|
- !ruby/object:Gem::Version
|
59
|
-
version: 1.0.
|
53
|
+
version: 1.0.6
|
60
54
|
- - "<"
|
61
55
|
- !ruby/object:Gem::Version
|
62
56
|
version: '2.0'
|
@@ -66,7 +60,7 @@ dependencies:
|
|
66
60
|
requirements:
|
67
61
|
- - ">="
|
68
62
|
- !ruby/object:Gem::Version
|
69
|
-
version: 1.0.
|
63
|
+
version: 1.0.6
|
70
64
|
- - "<"
|
71
65
|
- !ruby/object:Gem::Version
|
72
66
|
version: '2.0'
|
@@ -76,28 +70,54 @@ dependencies:
|
|
76
70
|
requirements:
|
77
71
|
- - "~>"
|
78
72
|
- !ruby/object:Gem::Version
|
79
|
-
version: '0.
|
73
|
+
version: '0.15'
|
74
|
+
- - ">="
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: 0.15.1
|
80
77
|
type: :runtime
|
81
78
|
prerelease: false
|
82
79
|
version_requirements: !ruby/object:Gem::Requirement
|
83
80
|
requirements:
|
84
81
|
- - "~>"
|
85
82
|
- !ruby/object:Gem::Version
|
86
|
-
version: '0.
|
83
|
+
version: '0.15'
|
84
|
+
- - ">="
|
85
|
+
- !ruby/object:Gem::Version
|
86
|
+
version: 0.15.1
|
87
|
+
- !ruby/object:Gem::Dependency
|
88
|
+
name: google-protobuf
|
89
|
+
requirement: !ruby/object:Gem::Requirement
|
90
|
+
requirements:
|
91
|
+
- - "~>"
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '3.15'
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 3.15.2
|
97
|
+
type: :runtime
|
98
|
+
prerelease: false
|
99
|
+
version_requirements: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '3.15'
|
104
|
+
- - ">="
|
105
|
+
- !ruby/object:Gem::Version
|
106
|
+
version: 3.15.2
|
87
107
|
- !ruby/object:Gem::Dependency
|
88
108
|
name: grpc
|
89
109
|
requirement: !ruby/object:Gem::Requirement
|
90
110
|
requirements:
|
91
111
|
- - "~>"
|
92
112
|
- !ruby/object:Gem::Version
|
93
|
-
version: '1.
|
113
|
+
version: '1.36'
|
94
114
|
type: :runtime
|
95
115
|
prerelease: false
|
96
116
|
version_requirements: !ruby/object:Gem::Requirement
|
97
117
|
requirements:
|
98
118
|
- - "~>"
|
99
119
|
- !ruby/object:Gem::Version
|
100
|
-
version: '1.
|
120
|
+
version: '1.36'
|
101
121
|
- !ruby/object:Gem::Dependency
|
102
122
|
name: google-cloud-core
|
103
123
|
requirement: !ruby/object:Gem::Requirement
|
@@ -118,14 +138,14 @@ dependencies:
|
|
118
138
|
requirements:
|
119
139
|
- - "~>"
|
120
140
|
- !ruby/object:Gem::Version
|
121
|
-
version: 1.
|
141
|
+
version: 1.25.1
|
122
142
|
type: :development
|
123
143
|
prerelease: false
|
124
144
|
version_requirements: !ruby/object:Gem::Requirement
|
125
145
|
requirements:
|
126
146
|
- - "~>"
|
127
147
|
- !ruby/object:Gem::Version
|
128
|
-
version: 1.
|
148
|
+
version: 1.25.1
|
129
149
|
- !ruby/object:Gem::Dependency
|
130
150
|
name: minitest
|
131
151
|
requirement: !ruby/object:Gem::Requirement
|
@@ -254,6 +274,10 @@ files:
|
|
254
274
|
- lib/gapic/operation/retry_policy.rb
|
255
275
|
- lib/gapic/paged_enumerable.rb
|
256
276
|
- lib/gapic/protobuf.rb
|
277
|
+
- lib/gapic/rest.rb
|
278
|
+
- lib/gapic/rest/client_stub.rb
|
279
|
+
- lib/gapic/rest/error.rb
|
280
|
+
- lib/gapic/rest/faraday_middleware.rb
|
257
281
|
- lib/gapic/stream_input.rb
|
258
282
|
homepage: https://github.com/googleapis/gapic-generator-ruby
|
259
283
|
licenses:
|
@@ -267,14 +291,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
267
291
|
requirements:
|
268
292
|
- - ">="
|
269
293
|
- !ruby/object:Gem::Version
|
270
|
-
version: '2.
|
294
|
+
version: '2.5'
|
271
295
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
272
296
|
requirements:
|
273
297
|
- - ">="
|
274
298
|
- !ruby/object:Gem::Version
|
275
299
|
version: '0'
|
276
300
|
requirements: []
|
277
|
-
rubygems_version: 3.
|
301
|
+
rubygems_version: 3.1.4
|
278
302
|
signing_key:
|
279
303
|
specification_version: 4
|
280
304
|
summary: Common code for GAPIC-generated API clients
|