google-cloud-run-v2 0.28.1 → 0.29.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/README.md +1 -1
- data/lib/google/cloud/run/v2/build_pb.rb +4 -25
- data/lib/google/cloud/run/v2/builds/client.rb +11 -1
- data/lib/google/cloud/run/v2/builds/rest/client.rb +11 -1
- data/lib/google/cloud/run/v2/condition_pb.rb +3 -25
- data/lib/google/cloud/run/v2/container_status_pb.rb +21 -0
- data/lib/google/cloud/run/v2/execution_pb.rb +2 -26
- data/lib/google/cloud/run/v2/execution_template_pb.rb +2 -24
- data/lib/google/cloud/run/v2/executions/client.rb +2 -0
- data/lib/google/cloud/run/v2/executions/operations.rb +2 -0
- data/lib/google/cloud/run/v2/executions/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/executions/rest/operations.rb +2 -0
- data/lib/google/cloud/run/v2/instance_pb.rb +42 -0
- data/lib/google/cloud/run/v2/instance_services_pb.rb +55 -0
- data/lib/google/cloud/run/v2/instance_split_pb.rb +2 -23
- data/lib/google/cloud/run/v2/instances/client.rb +1059 -0
- data/lib/google/cloud/run/v2/instances/credentials.rb +47 -0
- data/lib/google/cloud/run/v2/instances/operations.rb +851 -0
- data/lib/google/cloud/run/v2/instances/paths.rb +178 -0
- data/lib/google/cloud/run/v2/instances/rest/client.rb +962 -0
- data/lib/google/cloud/run/v2/instances/rest/operations.rb +1095 -0
- data/lib/google/cloud/run/v2/instances/rest/service_stub.rb +450 -0
- data/lib/google/cloud/run/v2/instances/rest.rb +53 -0
- data/lib/google/cloud/run/v2/instances.rb +56 -0
- data/lib/google/cloud/run/v2/job_pb.rb +3 -30
- data/lib/google/cloud/run/v2/jobs/client.rb +2 -0
- data/lib/google/cloud/run/v2/jobs/operations.rb +2 -0
- data/lib/google/cloud/run/v2/jobs/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/jobs/rest/operations.rb +2 -0
- data/lib/google/cloud/run/v2/k8s.min_pb.rb +5 -24
- data/lib/google/cloud/run/v2/rest.rb +1 -0
- data/lib/google/cloud/run/v2/revision_pb.rb +2 -29
- data/lib/google/cloud/run/v2/revision_template_pb.rb +2 -26
- data/lib/google/cloud/run/v2/revisions/client.rb +2 -0
- data/lib/google/cloud/run/v2/revisions/operations.rb +2 -0
- data/lib/google/cloud/run/v2/revisions/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/revisions/rest/operations.rb +2 -0
- data/lib/google/cloud/run/v2/service_pb.rb +4 -30
- data/lib/google/cloud/run/v2/services/client.rb +2 -0
- data/lib/google/cloud/run/v2/services/operations.rb +2 -0
- data/lib/google/cloud/run/v2/services/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/services/rest/operations.rb +2 -0
- data/lib/google/cloud/run/v2/status_pb.rb +2 -23
- data/lib/google/cloud/run/v2/task_pb.rb +2 -29
- data/lib/google/cloud/run/v2/task_template_pb.rb +2 -26
- data/lib/google/cloud/run/v2/tasks/client.rb +2 -0
- data/lib/google/cloud/run/v2/tasks/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/traffic_target_pb.rb +2 -23
- data/lib/google/cloud/run/v2/vendor_settings_pb.rb +3 -24
- data/lib/google/cloud/run/v2/version.rb +1 -1
- data/lib/google/cloud/run/v2/worker_pool_pb.rb +3 -30
- data/lib/google/cloud/run/v2/worker_pool_revision_template_pb.rb +3 -27
- data/lib/google/cloud/run/v2/worker_pools/client.rb +2 -0
- data/lib/google/cloud/run/v2/worker_pools/operations.rb +2 -0
- data/lib/google/cloud/run/v2/worker_pools/rest/client.rb +2 -0
- data/lib/google/cloud/run/v2/worker_pools/rest/operations.rb +2 -0
- data/lib/google/cloud/run/v2.rb +1 -0
- data/proto_docs/google/api/client.rb +149 -29
- data/proto_docs/google/api/routing.rb +7 -3
- data/proto_docs/google/cloud/run/v2/build.rb +11 -0
- data/proto_docs/google/cloud/run/v2/condition.rb +3 -0
- data/proto_docs/google/cloud/run/v2/container_status.rb +42 -0
- data/proto_docs/google/cloud/run/v2/instance.rb +328 -0
- data/proto_docs/google/cloud/run/v2/job.rb +2 -2
- data/proto_docs/google/cloud/run/v2/k8s.min.rb +37 -2
- data/proto_docs/google/cloud/run/v2/service.rb +32 -7
- data/proto_docs/google/cloud/run/v2/vendor_settings.rb +5 -0
- data/proto_docs/google/cloud/run/v2/worker_pool.rb +23 -22
- data/proto_docs/google/cloud/run/v2/worker_pool_revision_template.rb +3 -0
- metadata +18 -4
|
@@ -0,0 +1,450 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
|
+
#
|
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
# you may not use this file except in compliance with the License.
|
|
7
|
+
# You may obtain a copy of the License at
|
|
8
|
+
#
|
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
#
|
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
# See the License for the specific language governing permissions and
|
|
15
|
+
# limitations under the License.
|
|
16
|
+
|
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
|
18
|
+
|
|
19
|
+
require "google/cloud/run/v2/instance_pb"
|
|
20
|
+
|
|
21
|
+
module Google
|
|
22
|
+
module Cloud
|
|
23
|
+
module Run
|
|
24
|
+
module V2
|
|
25
|
+
module Instances
|
|
26
|
+
module Rest
|
|
27
|
+
##
|
|
28
|
+
# REST service stub for the Instances service.
|
|
29
|
+
# Service stub contains baseline method implementations
|
|
30
|
+
# including transcoding, making the REST call, and deserialing the response.
|
|
31
|
+
#
|
|
32
|
+
class ServiceStub
|
|
33
|
+
# @private
|
|
34
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger:
|
|
35
|
+
# These require statements are intentionally placed here to initialize
|
|
36
|
+
# the REST modules only when it's required.
|
|
37
|
+
require "gapic/rest"
|
|
38
|
+
|
|
39
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
|
40
|
+
endpoint_template: endpoint_template,
|
|
41
|
+
universe_domain: universe_domain,
|
|
42
|
+
credentials: credentials,
|
|
43
|
+
numeric_enums: true,
|
|
44
|
+
service_name: self.class,
|
|
45
|
+
raise_faraday_errors: false,
|
|
46
|
+
logger: logger
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
##
|
|
50
|
+
# The effective universe domain
|
|
51
|
+
#
|
|
52
|
+
# @return [String]
|
|
53
|
+
#
|
|
54
|
+
def universe_domain
|
|
55
|
+
@client_stub.universe_domain
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
##
|
|
59
|
+
# The effective endpoint
|
|
60
|
+
#
|
|
61
|
+
# @return [String]
|
|
62
|
+
#
|
|
63
|
+
def endpoint
|
|
64
|
+
@client_stub.endpoint
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
##
|
|
68
|
+
# The logger used for request/response debug logging.
|
|
69
|
+
#
|
|
70
|
+
# @return [Logger]
|
|
71
|
+
#
|
|
72
|
+
def logger stub: false
|
|
73
|
+
stub ? @client_stub.stub_logger : @client_stub.logger
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
##
|
|
77
|
+
# Baseline implementation for the create_instance REST call
|
|
78
|
+
#
|
|
79
|
+
# @param request_pb [::Google::Cloud::Run::V2::CreateInstanceRequest]
|
|
80
|
+
# A request object representing the call parameters. Required.
|
|
81
|
+
# @param options [::Gapic::CallOptions]
|
|
82
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
83
|
+
#
|
|
84
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
85
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
|
86
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
87
|
+
#
|
|
88
|
+
# @return [::Google::Longrunning::Operation]
|
|
89
|
+
# A result object deserialized from the server's reply
|
|
90
|
+
def create_instance request_pb, options = nil
|
|
91
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
92
|
+
|
|
93
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_instance_request request_pb
|
|
94
|
+
query_string_params = if query_string_params.any?
|
|
95
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
96
|
+
else
|
|
97
|
+
{}
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
response = @client_stub.make_http_request(
|
|
101
|
+
verb,
|
|
102
|
+
uri: uri,
|
|
103
|
+
body: body || "",
|
|
104
|
+
params: query_string_params,
|
|
105
|
+
method_name: "create_instance",
|
|
106
|
+
options: options
|
|
107
|
+
)
|
|
108
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
109
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
110
|
+
catch :response do
|
|
111
|
+
yield result, operation if block_given?
|
|
112
|
+
result
|
|
113
|
+
end
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
##
|
|
117
|
+
# Baseline implementation for the delete_instance REST call
|
|
118
|
+
#
|
|
119
|
+
# @param request_pb [::Google::Cloud::Run::V2::DeleteInstanceRequest]
|
|
120
|
+
# A request object representing the call parameters. Required.
|
|
121
|
+
# @param options [::Gapic::CallOptions]
|
|
122
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
123
|
+
#
|
|
124
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
125
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
|
126
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
127
|
+
#
|
|
128
|
+
# @return [::Google::Longrunning::Operation]
|
|
129
|
+
# A result object deserialized from the server's reply
|
|
130
|
+
def delete_instance request_pb, options = nil
|
|
131
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
132
|
+
|
|
133
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_instance_request request_pb
|
|
134
|
+
query_string_params = if query_string_params.any?
|
|
135
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
136
|
+
else
|
|
137
|
+
{}
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
response = @client_stub.make_http_request(
|
|
141
|
+
verb,
|
|
142
|
+
uri: uri,
|
|
143
|
+
body: body || "",
|
|
144
|
+
params: query_string_params,
|
|
145
|
+
method_name: "delete_instance",
|
|
146
|
+
options: options
|
|
147
|
+
)
|
|
148
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
149
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
150
|
+
catch :response do
|
|
151
|
+
yield result, operation if block_given?
|
|
152
|
+
result
|
|
153
|
+
end
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
##
|
|
157
|
+
# Baseline implementation for the get_instance REST call
|
|
158
|
+
#
|
|
159
|
+
# @param request_pb [::Google::Cloud::Run::V2::GetInstanceRequest]
|
|
160
|
+
# A request object representing the call parameters. Required.
|
|
161
|
+
# @param options [::Gapic::CallOptions]
|
|
162
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
163
|
+
#
|
|
164
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
165
|
+
# @yieldparam result [::Google::Cloud::Run::V2::Instance]
|
|
166
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
167
|
+
#
|
|
168
|
+
# @return [::Google::Cloud::Run::V2::Instance]
|
|
169
|
+
# A result object deserialized from the server's reply
|
|
170
|
+
def get_instance request_pb, options = nil
|
|
171
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
172
|
+
|
|
173
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_instance_request request_pb
|
|
174
|
+
query_string_params = if query_string_params.any?
|
|
175
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
176
|
+
else
|
|
177
|
+
{}
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
response = @client_stub.make_http_request(
|
|
181
|
+
verb,
|
|
182
|
+
uri: uri,
|
|
183
|
+
body: body || "",
|
|
184
|
+
params: query_string_params,
|
|
185
|
+
method_name: "get_instance",
|
|
186
|
+
options: options
|
|
187
|
+
)
|
|
188
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
189
|
+
result = ::Google::Cloud::Run::V2::Instance.decode_json response.body, ignore_unknown_fields: true
|
|
190
|
+
catch :response do
|
|
191
|
+
yield result, operation if block_given?
|
|
192
|
+
result
|
|
193
|
+
end
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
##
|
|
197
|
+
# Baseline implementation for the list_instances REST call
|
|
198
|
+
#
|
|
199
|
+
# @param request_pb [::Google::Cloud::Run::V2::ListInstancesRequest]
|
|
200
|
+
# A request object representing the call parameters. Required.
|
|
201
|
+
# @param options [::Gapic::CallOptions]
|
|
202
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
203
|
+
#
|
|
204
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
205
|
+
# @yieldparam result [::Google::Cloud::Run::V2::ListInstancesResponse]
|
|
206
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
207
|
+
#
|
|
208
|
+
# @return [::Google::Cloud::Run::V2::ListInstancesResponse]
|
|
209
|
+
# A result object deserialized from the server's reply
|
|
210
|
+
def list_instances request_pb, options = nil
|
|
211
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
212
|
+
|
|
213
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_instances_request request_pb
|
|
214
|
+
query_string_params = if query_string_params.any?
|
|
215
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
216
|
+
else
|
|
217
|
+
{}
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
response = @client_stub.make_http_request(
|
|
221
|
+
verb,
|
|
222
|
+
uri: uri,
|
|
223
|
+
body: body || "",
|
|
224
|
+
params: query_string_params,
|
|
225
|
+
method_name: "list_instances",
|
|
226
|
+
options: options
|
|
227
|
+
)
|
|
228
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
229
|
+
result = ::Google::Cloud::Run::V2::ListInstancesResponse.decode_json response.body, ignore_unknown_fields: true
|
|
230
|
+
catch :response do
|
|
231
|
+
yield result, operation if block_given?
|
|
232
|
+
result
|
|
233
|
+
end
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
##
|
|
237
|
+
# Baseline implementation for the stop_instance REST call
|
|
238
|
+
#
|
|
239
|
+
# @param request_pb [::Google::Cloud::Run::V2::StopInstanceRequest]
|
|
240
|
+
# A request object representing the call parameters. Required.
|
|
241
|
+
# @param options [::Gapic::CallOptions]
|
|
242
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
243
|
+
#
|
|
244
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
245
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
|
246
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
247
|
+
#
|
|
248
|
+
# @return [::Google::Longrunning::Operation]
|
|
249
|
+
# A result object deserialized from the server's reply
|
|
250
|
+
def stop_instance request_pb, options = nil
|
|
251
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
252
|
+
|
|
253
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_stop_instance_request request_pb
|
|
254
|
+
query_string_params = if query_string_params.any?
|
|
255
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
256
|
+
else
|
|
257
|
+
{}
|
|
258
|
+
end
|
|
259
|
+
|
|
260
|
+
response = @client_stub.make_http_request(
|
|
261
|
+
verb,
|
|
262
|
+
uri: uri,
|
|
263
|
+
body: body || "",
|
|
264
|
+
params: query_string_params,
|
|
265
|
+
method_name: "stop_instance",
|
|
266
|
+
options: options
|
|
267
|
+
)
|
|
268
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
269
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
270
|
+
catch :response do
|
|
271
|
+
yield result, operation if block_given?
|
|
272
|
+
result
|
|
273
|
+
end
|
|
274
|
+
end
|
|
275
|
+
|
|
276
|
+
##
|
|
277
|
+
# Baseline implementation for the start_instance REST call
|
|
278
|
+
#
|
|
279
|
+
# @param request_pb [::Google::Cloud::Run::V2::StartInstanceRequest]
|
|
280
|
+
# A request object representing the call parameters. Required.
|
|
281
|
+
# @param options [::Gapic::CallOptions]
|
|
282
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
283
|
+
#
|
|
284
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
285
|
+
# @yieldparam result [::Google::Longrunning::Operation]
|
|
286
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
287
|
+
#
|
|
288
|
+
# @return [::Google::Longrunning::Operation]
|
|
289
|
+
# A result object deserialized from the server's reply
|
|
290
|
+
def start_instance request_pb, options = nil
|
|
291
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
292
|
+
|
|
293
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_start_instance_request request_pb
|
|
294
|
+
query_string_params = if query_string_params.any?
|
|
295
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
296
|
+
else
|
|
297
|
+
{}
|
|
298
|
+
end
|
|
299
|
+
|
|
300
|
+
response = @client_stub.make_http_request(
|
|
301
|
+
verb,
|
|
302
|
+
uri: uri,
|
|
303
|
+
body: body || "",
|
|
304
|
+
params: query_string_params,
|
|
305
|
+
method_name: "start_instance",
|
|
306
|
+
options: options
|
|
307
|
+
)
|
|
308
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
309
|
+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
310
|
+
catch :response do
|
|
311
|
+
yield result, operation if block_given?
|
|
312
|
+
result
|
|
313
|
+
end
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
##
|
|
317
|
+
# @private
|
|
318
|
+
#
|
|
319
|
+
# GRPC transcoding helper method for the create_instance REST call
|
|
320
|
+
#
|
|
321
|
+
# @param request_pb [::Google::Cloud::Run::V2::CreateInstanceRequest]
|
|
322
|
+
# A request object representing the call parameters. Required.
|
|
323
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
324
|
+
# Uri, Body, Query string parameters
|
|
325
|
+
def self.transcode_create_instance_request request_pb
|
|
326
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
327
|
+
.with_bindings(
|
|
328
|
+
uri_method: :post,
|
|
329
|
+
uri_template: "/v2/{parent}/instances",
|
|
330
|
+
body: "instance",
|
|
331
|
+
matches: [
|
|
332
|
+
["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
|
|
333
|
+
]
|
|
334
|
+
)
|
|
335
|
+
transcoder.transcode request_pb
|
|
336
|
+
end
|
|
337
|
+
|
|
338
|
+
##
|
|
339
|
+
# @private
|
|
340
|
+
#
|
|
341
|
+
# GRPC transcoding helper method for the delete_instance REST call
|
|
342
|
+
#
|
|
343
|
+
# @param request_pb [::Google::Cloud::Run::V2::DeleteInstanceRequest]
|
|
344
|
+
# A request object representing the call parameters. Required.
|
|
345
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
346
|
+
# Uri, Body, Query string parameters
|
|
347
|
+
def self.transcode_delete_instance_request request_pb
|
|
348
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
349
|
+
.with_bindings(
|
|
350
|
+
uri_method: :delete,
|
|
351
|
+
uri_template: "/v2/{name}",
|
|
352
|
+
matches: [
|
|
353
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
|
|
354
|
+
]
|
|
355
|
+
)
|
|
356
|
+
transcoder.transcode request_pb
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
##
|
|
360
|
+
# @private
|
|
361
|
+
#
|
|
362
|
+
# GRPC transcoding helper method for the get_instance REST call
|
|
363
|
+
#
|
|
364
|
+
# @param request_pb [::Google::Cloud::Run::V2::GetInstanceRequest]
|
|
365
|
+
# A request object representing the call parameters. Required.
|
|
366
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
367
|
+
# Uri, Body, Query string parameters
|
|
368
|
+
def self.transcode_get_instance_request request_pb
|
|
369
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
370
|
+
.with_bindings(
|
|
371
|
+
uri_method: :get,
|
|
372
|
+
uri_template: "/v2/{name}",
|
|
373
|
+
matches: [
|
|
374
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
|
|
375
|
+
]
|
|
376
|
+
)
|
|
377
|
+
transcoder.transcode request_pb
|
|
378
|
+
end
|
|
379
|
+
|
|
380
|
+
##
|
|
381
|
+
# @private
|
|
382
|
+
#
|
|
383
|
+
# GRPC transcoding helper method for the list_instances REST call
|
|
384
|
+
#
|
|
385
|
+
# @param request_pb [::Google::Cloud::Run::V2::ListInstancesRequest]
|
|
386
|
+
# A request object representing the call parameters. Required.
|
|
387
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
388
|
+
# Uri, Body, Query string parameters
|
|
389
|
+
def self.transcode_list_instances_request request_pb
|
|
390
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
391
|
+
.with_bindings(
|
|
392
|
+
uri_method: :get,
|
|
393
|
+
uri_template: "/v2/{parent}/instances",
|
|
394
|
+
matches: [
|
|
395
|
+
["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
|
|
396
|
+
]
|
|
397
|
+
)
|
|
398
|
+
transcoder.transcode request_pb
|
|
399
|
+
end
|
|
400
|
+
|
|
401
|
+
##
|
|
402
|
+
# @private
|
|
403
|
+
#
|
|
404
|
+
# GRPC transcoding helper method for the stop_instance REST call
|
|
405
|
+
#
|
|
406
|
+
# @param request_pb [::Google::Cloud::Run::V2::StopInstanceRequest]
|
|
407
|
+
# A request object representing the call parameters. Required.
|
|
408
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
409
|
+
# Uri, Body, Query string parameters
|
|
410
|
+
def self.transcode_stop_instance_request request_pb
|
|
411
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
412
|
+
.with_bindings(
|
|
413
|
+
uri_method: :post,
|
|
414
|
+
uri_template: "/v2/{name}:stop",
|
|
415
|
+
body: "*",
|
|
416
|
+
matches: [
|
|
417
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
|
|
418
|
+
]
|
|
419
|
+
)
|
|
420
|
+
transcoder.transcode request_pb
|
|
421
|
+
end
|
|
422
|
+
|
|
423
|
+
##
|
|
424
|
+
# @private
|
|
425
|
+
#
|
|
426
|
+
# GRPC transcoding helper method for the start_instance REST call
|
|
427
|
+
#
|
|
428
|
+
# @param request_pb [::Google::Cloud::Run::V2::StartInstanceRequest]
|
|
429
|
+
# A request object representing the call parameters. Required.
|
|
430
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
431
|
+
# Uri, Body, Query string parameters
|
|
432
|
+
def self.transcode_start_instance_request request_pb
|
|
433
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
434
|
+
.with_bindings(
|
|
435
|
+
uri_method: :post,
|
|
436
|
+
uri_template: "/v2/{name}:start",
|
|
437
|
+
body: "*",
|
|
438
|
+
matches: [
|
|
439
|
+
["name", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
|
|
440
|
+
]
|
|
441
|
+
)
|
|
442
|
+
transcoder.transcode request_pb
|
|
443
|
+
end
|
|
444
|
+
end
|
|
445
|
+
end
|
|
446
|
+
end
|
|
447
|
+
end
|
|
448
|
+
end
|
|
449
|
+
end
|
|
450
|
+
end
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
|
+
#
|
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
# you may not use this file except in compliance with the License.
|
|
7
|
+
# You may obtain a copy of the License at
|
|
8
|
+
#
|
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
#
|
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
# See the License for the specific language governing permissions and
|
|
15
|
+
# limitations under the License.
|
|
16
|
+
|
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
|
18
|
+
|
|
19
|
+
require "gapic/rest"
|
|
20
|
+
require "gapic/config"
|
|
21
|
+
require "gapic/config/method"
|
|
22
|
+
|
|
23
|
+
require "google/cloud/run/v2/version"
|
|
24
|
+
|
|
25
|
+
require "google/cloud/run/v2/instances/credentials"
|
|
26
|
+
require "google/cloud/run/v2/instances/paths"
|
|
27
|
+
require "google/cloud/run/v2/instances/rest/operations"
|
|
28
|
+
require "google/cloud/run/v2/instances/rest/client"
|
|
29
|
+
|
|
30
|
+
module Google
|
|
31
|
+
module Cloud
|
|
32
|
+
module Run
|
|
33
|
+
module V2
|
|
34
|
+
##
|
|
35
|
+
# The Cloud Run Instances API allows you to manage Cloud Run Instances.
|
|
36
|
+
#
|
|
37
|
+
# To load this service and instantiate a REST client:
|
|
38
|
+
#
|
|
39
|
+
# require "google/cloud/run/v2/instances/rest"
|
|
40
|
+
# client = ::Google::Cloud::Run::V2::Instances::Rest::Client.new
|
|
41
|
+
#
|
|
42
|
+
module Instances
|
|
43
|
+
# Client for the REST transport
|
|
44
|
+
module Rest
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
end
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
helper_path = ::File.join __dir__, "rest", "helpers.rb"
|
|
53
|
+
require "google/cloud/run/v2/instances/rest/helpers" if ::File.file? helper_path
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
|
+
#
|
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
# you may not use this file except in compliance with the License.
|
|
7
|
+
# You may obtain a copy of the License at
|
|
8
|
+
#
|
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
#
|
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
# See the License for the specific language governing permissions and
|
|
15
|
+
# limitations under the License.
|
|
16
|
+
|
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
|
18
|
+
|
|
19
|
+
require "gapic/common"
|
|
20
|
+
require "gapic/config"
|
|
21
|
+
require "gapic/config/method"
|
|
22
|
+
|
|
23
|
+
require "google/cloud/run/v2/version"
|
|
24
|
+
|
|
25
|
+
require "google/cloud/run/v2/instances/credentials"
|
|
26
|
+
require "google/cloud/run/v2/instances/paths"
|
|
27
|
+
require "google/cloud/run/v2/instances/operations"
|
|
28
|
+
require "google/cloud/run/v2/instances/client"
|
|
29
|
+
require "google/cloud/run/v2/instances/rest"
|
|
30
|
+
|
|
31
|
+
module Google
|
|
32
|
+
module Cloud
|
|
33
|
+
module Run
|
|
34
|
+
module V2
|
|
35
|
+
##
|
|
36
|
+
# The Cloud Run Instances API allows you to manage Cloud Run Instances.
|
|
37
|
+
#
|
|
38
|
+
# @example Load this service and instantiate a gRPC client
|
|
39
|
+
#
|
|
40
|
+
# require "google/cloud/run/v2/instances"
|
|
41
|
+
# client = ::Google::Cloud::Run::V2::Instances::Client.new
|
|
42
|
+
#
|
|
43
|
+
# @example Load this service and instantiate a REST client
|
|
44
|
+
#
|
|
45
|
+
# require "google/cloud/run/v2/instances/rest"
|
|
46
|
+
# client = ::Google::Cloud::Run::V2::Instances::Rest::Client.new
|
|
47
|
+
#
|
|
48
|
+
module Instances
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
helper_path = ::File.join __dir__, "instances", "helpers.rb"
|
|
56
|
+
require "google/cloud/run/v2/instances/helpers" if ::File.file? helper_path
|
|
@@ -22,37 +22,10 @@ require 'google/protobuf/duration_pb'
|
|
|
22
22
|
require 'google/protobuf/timestamp_pb'
|
|
23
23
|
|
|
24
24
|
|
|
25
|
-
descriptor_data = "\n\x1dgoogle/cloud/run/v2/job.proto\x12\x13google.cloud.run.v2\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1dgoogle/api/launch_stage.proto\x1a\x19google/api/resource.proto\x1a\x18google/api/routing.proto\x1a#google/cloud/run/v2/condition.proto\x1a#google/cloud/run/v2/execution.proto\x1a,google/cloud/run/v2/execution_template.proto\x1a!google/cloud/run/v2/k8s.min.proto\x1a)google/cloud/run/v2/vendor_settings.proto\x1a\x1egoogle/iam/v1/iam_policy.proto\x1a\x1agoogle/iam/v1/policy.proto\x1a#google/longrunning/operations.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x9a\x01\n\x10\x43reateJobRequest\x12.\n\x06parent\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\x12\x16run.googleapis.com/Job\x12*\n\x03job\x18\x02 \x01(\x0b\x32\x18.google.cloud.run.v2.JobB\x03\xe0\x41\x02\x12\x13\n\x06job_id\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x15\n\rvalidate_only\x18\x04 \x01(\x08\"=\n\rGetJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\"q\n\x10UpdateJobRequest\x12*\n\x03job\x18\x01 \x01(\x0b\x32\x18.google.cloud.run.v2.JobB\x03\xe0\x41\x02\x12\x15\n\rvalidate_only\x18\x03 \x01(\x08\x12\x1a\n\rallow_missing\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"~\n\x0fListJobsRequest\x12.\n\x06parent\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\x12\x16run.googleapis.com/Job\x12\x11\n\tpage_size\x18\x02 \x01(\x05\x12\x12\n\npage_token\x18\x03 \x01(\t\x12\x14\n\x0cshow_deleted\x18\x04 \x01(\x08\"S\n\x10ListJobsResponse\x12&\n\x04jobs\x18\x01 \x03(\x0b\x32\x18.google.cloud.run.v2.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"e\n\x10\x44\x65leteJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\x12\x15\n\rvalidate_only\x18\x03 \x01(\x08\x12\x0c\n\x04\x65tag\x18\x04 \x01(\t\"\xcc\x03\n\rRunJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\x12\x15\n\rvalidate_only\x18\x02 \x01(\x08\x12\x0c\n\x04\x65tag\x18\x03 \x01(\t\x12?\n\toverrides\x18\x04 \x01(\x0b\x32,.google.cloud.run.v2.RunJobRequest.Overrides\x1a\xa6\x02\n\tOverrides\x12[\n\x13\x63ontainer_overrides\x18\x01 \x03(\x0b\x32>.google.cloud.run.v2.RunJobRequest.Overrides.ContainerOverride\x12\x17\n\ntask_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12*\n\x07timeout\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x1aw\n\x11\x43ontainerOverride\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x11\n\x04\x61rgs\x18\x02 \x03(\tB\x03\xe0\x41\x01\x12(\n\x03\x65nv\x18\x03 \x03(\x0b\x32\x1b.google.cloud.run.v2.EnvVar\x12\x17\n\nclear_args\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"\xfa\t\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x03uid\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\ngeneration\x18\x03 \x01(\x03\x42\x03\xe0\x41\x03\x12\x34\n\x06labels\x18\x04 \x03(\x0b\x32$.google.cloud.run.v2.Job.LabelsEntry\x12>\n\x0b\x61nnotations\x18\x05 \x03(\x0b\x32).google.cloud.run.v2.Job.AnnotationsEntry\x12\x34\n\x0b\x63reate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0b\x64\x65lete_time\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0b\x65xpire_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x14\n\x07\x63reator\x18\n \x01(\tB\x03\xe0\x41\x03\x12\x1a\n\rlast_modifier\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12\x0e\n\x06\x63lient\x18\x0c \x01(\t\x12\x16\n\x0e\x63lient_version\x18\r \x01(\t\x12-\n\x0claunch_stage\x18\x0e \x01(\x0e\x32\x17.google.api.LaunchStage\x12\x46\n\x14\x62inary_authorization\x18\x0f \x01(\x0b\x32(.google.cloud.run.v2.BinaryAuthorization\x12=\n\x08template\x18\x10 \x01(\x0b\x32&.google.cloud.run.v2.ExecutionTemplateB\x03\xe0\x41\x02\x12 \n\x13observed_generation\x18\x11 \x01(\x03\x42\x03\xe0\x41\x03\x12?\n\x12terminal_condition\x18\x12 \x01(\x0b\x32\x1e.google.cloud.run.v2.ConditionB\x03\xe0\x41\x03\x12\x37\n\nconditions\x18\x13 \x03(\x0b\x32\x1e.google.cloud.run.v2.ConditionB\x03\xe0\x41\x03\x12\x1c\n\x0f\x65xecution_count\x18\x14 \x01(\x05\x42\x03\xe0\x41\x03\x12N\n\x18latest_created_execution\x18\x16 \x01(\x0b\x32\'.google.cloud.run.v2.ExecutionReferenceB\x03\xe0\x41\x03\x12\x18\n\x0breconciling\x18\x17 \x01(\x08\x42\x03\xe0\x41\x03\x12\x1a\n\rsatisfies_pzs\x18\x19 \x01(\x08\x42\x03\xe0\x41\x03\x12\x1f\n\x15start_execution_token\x18\x1a \x01(\tH\x00\x12\x1d\n\x13run_execution_token\x18\x1b \x01(\tH\x00\x12\x11\n\x04\x65tag\x18\x63 \x01(\tB\x03\xe0\x41\
|
|
25
|
+
descriptor_data = "\n\x1dgoogle/cloud/run/v2/job.proto\x12\x13google.cloud.run.v2\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1dgoogle/api/launch_stage.proto\x1a\x19google/api/resource.proto\x1a\x18google/api/routing.proto\x1a#google/cloud/run/v2/condition.proto\x1a#google/cloud/run/v2/execution.proto\x1a,google/cloud/run/v2/execution_template.proto\x1a!google/cloud/run/v2/k8s.min.proto\x1a)google/cloud/run/v2/vendor_settings.proto\x1a\x1egoogle/iam/v1/iam_policy.proto\x1a\x1agoogle/iam/v1/policy.proto\x1a#google/longrunning/operations.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x9a\x01\n\x10\x43reateJobRequest\x12.\n\x06parent\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\x12\x16run.googleapis.com/Job\x12*\n\x03job\x18\x02 \x01(\x0b\x32\x18.google.cloud.run.v2.JobB\x03\xe0\x41\x02\x12\x13\n\x06job_id\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x15\n\rvalidate_only\x18\x04 \x01(\x08\"=\n\rGetJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\"q\n\x10UpdateJobRequest\x12*\n\x03job\x18\x01 \x01(\x0b\x32\x18.google.cloud.run.v2.JobB\x03\xe0\x41\x02\x12\x15\n\rvalidate_only\x18\x03 \x01(\x08\x12\x1a\n\rallow_missing\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"~\n\x0fListJobsRequest\x12.\n\x06parent\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\x12\x16run.googleapis.com/Job\x12\x11\n\tpage_size\x18\x02 \x01(\x05\x12\x12\n\npage_token\x18\x03 \x01(\t\x12\x14\n\x0cshow_deleted\x18\x04 \x01(\x08\"S\n\x10ListJobsResponse\x12&\n\x04jobs\x18\x01 \x03(\x0b\x32\x18.google.cloud.run.v2.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"e\n\x10\x44\x65leteJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\x12\x15\n\rvalidate_only\x18\x03 \x01(\x08\x12\x0c\n\x04\x65tag\x18\x04 \x01(\t\"\xcc\x03\n\rRunJobRequest\x12,\n\x04name\x18\x01 \x01(\tB\x1e\xe0\x41\x02\xfa\x41\x18\n\x16run.googleapis.com/Job\x12\x15\n\rvalidate_only\x18\x02 \x01(\x08\x12\x0c\n\x04\x65tag\x18\x03 \x01(\t\x12?\n\toverrides\x18\x04 \x01(\x0b\x32,.google.cloud.run.v2.RunJobRequest.Overrides\x1a\xa6\x02\n\tOverrides\x12[\n\x13\x63ontainer_overrides\x18\x01 \x03(\x0b\x32>.google.cloud.run.v2.RunJobRequest.Overrides.ContainerOverride\x12\x17\n\ntask_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12*\n\x07timeout\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x1aw\n\x11\x43ontainerOverride\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x11\n\x04\x61rgs\x18\x02 \x03(\tB\x03\xe0\x41\x01\x12(\n\x03\x65nv\x18\x03 \x03(\x0b\x32\x1b.google.cloud.run.v2.EnvVar\x12\x17\n\nclear_args\x18\x04 \x01(\x08\x42\x03\xe0\x41\x01\"\xfa\t\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x03uid\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\ngeneration\x18\x03 \x01(\x03\x42\x03\xe0\x41\x03\x12\x34\n\x06labels\x18\x04 \x03(\x0b\x32$.google.cloud.run.v2.Job.LabelsEntry\x12>\n\x0b\x61nnotations\x18\x05 \x03(\x0b\x32).google.cloud.run.v2.Job.AnnotationsEntry\x12\x34\n\x0b\x63reate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0b\x64\x65lete_time\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0b\x65xpire_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x14\n\x07\x63reator\x18\n \x01(\tB\x03\xe0\x41\x03\x12\x1a\n\rlast_modifier\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12\x0e\n\x06\x63lient\x18\x0c \x01(\t\x12\x16\n\x0e\x63lient_version\x18\r \x01(\t\x12-\n\x0claunch_stage\x18\x0e \x01(\x0e\x32\x17.google.api.LaunchStage\x12\x46\n\x14\x62inary_authorization\x18\x0f \x01(\x0b\x32(.google.cloud.run.v2.BinaryAuthorization\x12=\n\x08template\x18\x10 \x01(\x0b\x32&.google.cloud.run.v2.ExecutionTemplateB\x03\xe0\x41\x02\x12 \n\x13observed_generation\x18\x11 \x01(\x03\x42\x03\xe0\x41\x03\x12?\n\x12terminal_condition\x18\x12 \x01(\x0b\x32\x1e.google.cloud.run.v2.ConditionB\x03\xe0\x41\x03\x12\x37\n\nconditions\x18\x13 \x03(\x0b\x32\x1e.google.cloud.run.v2.ConditionB\x03\xe0\x41\x03\x12\x1c\n\x0f\x65xecution_count\x18\x14 \x01(\x05\x42\x03\xe0\x41\x03\x12N\n\x18latest_created_execution\x18\x16 \x01(\x0b\x32\'.google.cloud.run.v2.ExecutionReferenceB\x03\xe0\x41\x03\x12\x18\n\x0breconciling\x18\x17 \x01(\x08\x42\x03\xe0\x41\x03\x12\x1a\n\rsatisfies_pzs\x18\x19 \x01(\x08\x42\x03\xe0\x41\x03\x12\x1f\n\x15start_execution_token\x18\x1a \x01(\tH\x00\x12\x1d\n\x13run_execution_token\x18\x1b \x01(\tH\x00\x12\x11\n\x04\x65tag\x18\x63 \x01(\tB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x1a\x32\n\x10\x41nnotationsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:R\xea\x41O\n\x16run.googleapis.com/Job\x12\x32projects/{project}/locations/{location}/jobs/{job}R\x01\x01\x42\x12\n\x10\x63reate_execution\"\xdf\x03\n\x12\x45xecutionReference\x12/\n\x04name\x18\x01 \x01(\tB!\xfa\x41\x1e\n\x1crun.googleapis.com/Execution\x12/\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x33\n\x0f\x63ompletion_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12/\n\x0b\x64\x65lete_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12S\n\x11\x63ompletion_status\x18\x04 \x01(\x0e\x32\x38.google.cloud.run.v2.ExecutionReference.CompletionStatus\"\xab\x01\n\x10\x43ompletionStatus\x12!\n\x1d\x43OMPLETION_STATUS_UNSPECIFIED\x10\x00\x12\x17\n\x13\x45XECUTION_SUCCEEDED\x10\x01\x12\x14\n\x10\x45XECUTION_FAILED\x10\x02\x12\x15\n\x11\x45XECUTION_RUNNING\x10\x03\x12\x15\n\x11\x45XECUTION_PENDING\x10\x04\x12\x17\n\x13\x45XECUTION_CANCELLED\x10\x05\x32\x8a\x0e\n\x04Jobs\x12\xdd\x01\n\tCreateJob\x12%.google.cloud.run.v2.CreateJobRequest\x1a\x1d.google.longrunning.Operation\"\x89\x01\xca\x41\n\n\x03Job\x12\x03Job\xda\x41\x11parent,job,job_id\x82\xd3\xe4\x93\x02/\"(/v2/{parent=projects/*/locations/*}/jobs:\x03job\x8a\xd3\xe4\x93\x02-\x12+\n\x06parent\x12!projects/*/locations/{location=*}\x12\xb3\x01\n\x06GetJob\x12\".google.cloud.run.v2.GetJobRequest\x1a\x18.google.cloud.run.v2.Job\"k\xda\x41\x04name\x82\xd3\xe4\x93\x02*\x12(/v2/{name=projects/*/locations/*/jobs/*}\x8a\xd3\xe4\x93\x02.\x12,\n\x04name\x12$projects/*/locations/{location=*}/**\x12\xc5\x01\n\x08ListJobs\x12$.google.cloud.run.v2.ListJobsRequest\x1a%.google.cloud.run.v2.ListJobsResponse\"l\xda\x41\x06parent\x82\xd3\xe4\x93\x02*\x12(/v2/{parent=projects/*/locations/*}/jobs\x8a\xd3\xe4\x93\x02-\x12+\n\x06parent\x12!projects/*/locations/{location=*}\x12\xd8\x01\n\tUpdateJob\x12%.google.cloud.run.v2.UpdateJobRequest\x1a\x1d.google.longrunning.Operation\"\x84\x01\xca\x41\n\n\x03Job\x12\x03Job\xda\x41\x03job\x82\xd3\xe4\x93\x02\x33\x32,/v2/{job.name=projects/*/locations/*/jobs/*}:\x03job\x8a\xd3\xe4\x93\x02\x32\x12\x30\n\x08job.name\x12$projects/*/locations/{location=*}/**\x12\xcb\x01\n\tDeleteJob\x12%.google.cloud.run.v2.DeleteJobRequest\x1a\x1d.google.longrunning.Operation\"x\xca\x41\n\n\x03Job\x12\x03Job\xda\x41\x04name\x82\xd3\xe4\x93\x02**(/v2/{name=projects/*/locations/*/jobs/*}\x8a\xd3\xe4\x93\x02.\x12,\n\x04name\x12$projects/*/locations/{location=*}/**\x12\xd9\x01\n\x06RunJob\x12\".google.cloud.run.v2.RunJobRequest\x1a\x1d.google.longrunning.Operation\"\x8b\x01\xca\x41\x16\n\tExecution\x12\tExecution\xda\x41\x04name\x82\xd3\xe4\x93\x02\x31\",/v2/{name=projects/*/locations/*/jobs/*}:run:\x01*\x8a\xd3\xe4\x93\x02.\x12,\n\x04name\x12$projects/*/locations/{location=*}/**\x12\x8c\x01\n\x0cGetIamPolicy\x12\".google.iam.v1.GetIamPolicyRequest\x1a\x15.google.iam.v1.Policy\"A\x82\xd3\xe4\x93\x02;\x12\x39/v2/{resource=projects/*/locations/*/jobs/*}:getIamPolicy\x12\x8f\x01\n\x0cSetIamPolicy\x12\".google.iam.v1.SetIamPolicyRequest\x1a\x15.google.iam.v1.Policy\"D\x82\xd3\xe4\x93\x02>\"9/v2/{resource=projects/*/locations/*/jobs/*}:setIamPolicy:\x01*\x12\xb5\x01\n\x12TestIamPermissions\x12(.google.iam.v1.TestIamPermissionsRequest\x1a).google.iam.v1.TestIamPermissionsResponse\"J\x82\xd3\xe4\x93\x02\x44\"?/v2/{resource=projects/*/locations/*/jobs/*}:testIamPermissions:\x01*\x1a\x46\xca\x41\x12run.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformBP\n\x17\x63om.google.cloud.run.v2B\x08JobProtoP\x01Z)cloud.google.com/go/run/apiv2/runpb;runpbb\x06proto3"
|
|
26
26
|
|
|
27
|
-
pool = Google::Protobuf::DescriptorPool.generated_pool
|
|
28
|
-
|
|
29
|
-
begin
|
|
30
|
-
pool.add_serialized_file(descriptor_data)
|
|
31
|
-
rescue TypeError
|
|
32
|
-
# Compatibility code: will be removed in the next major version.
|
|
33
|
-
require 'google/protobuf/descriptor_pb'
|
|
34
|
-
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
|
35
|
-
parsed.clear_dependency
|
|
36
|
-
serialized = parsed.class.encode(parsed)
|
|
37
|
-
file = pool.add_serialized_file(serialized)
|
|
38
|
-
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
|
39
|
-
imports = [
|
|
40
|
-
["google.protobuf.Duration", "google/protobuf/duration.proto"],
|
|
41
|
-
["google.cloud.run.v2.EnvVar", "google/cloud/run/v2/k8s.min.proto"],
|
|
42
|
-
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
|
43
|
-
["google.cloud.run.v2.BinaryAuthorization", "google/cloud/run/v2/vendor_settings.proto"],
|
|
44
|
-
["google.cloud.run.v2.ExecutionTemplate", "google/cloud/run/v2/execution_template.proto"],
|
|
45
|
-
["google.cloud.run.v2.Condition", "google/cloud/run/v2/condition.proto"],
|
|
46
|
-
]
|
|
47
|
-
imports.each do |type_name, expected_filename|
|
|
48
|
-
import_file = pool.lookup(type_name).file_descriptor
|
|
49
|
-
if import_file.name != expected_filename
|
|
50
|
-
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
|
51
|
-
end
|
|
52
|
-
end
|
|
53
|
-
warn "Each proto file must use a consistent fully-qualified name."
|
|
54
|
-
warn "This will become an error in the next major version."
|
|
55
|
-
end
|
|
27
|
+
pool = ::Google::Protobuf::DescriptorPool.generated_pool
|
|
28
|
+
pool.add_serialized_file(descriptor_data)
|
|
56
29
|
|
|
57
30
|
module Google
|
|
58
31
|
module Cloud
|
|
@@ -1207,6 +1207,7 @@ module Google
|
|
|
1207
1207
|
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
|
1208
1208
|
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
|
1209
1209
|
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
|
1210
|
+
# * `:jitter` (*type:* `Numeric`) - The jitter in seconds. Default: 1.0.
|
|
1210
1211
|
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
|
1211
1212
|
# trigger a retry.
|
|
1212
1213
|
# @return [::Hash]
|
|
@@ -1290,6 +1291,7 @@ module Google
|
|
|
1290
1291
|
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
|
1291
1292
|
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
|
1292
1293
|
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
|
1294
|
+
# * `:jitter` (*type:* `Numeric`) - The jitter in seconds. Default: 1.0.
|
|
1293
1295
|
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
|
1294
1296
|
# trigger a retry.
|
|
1295
1297
|
#
|