google-cloud-dataproc-v1 0.6.1 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +8 -8
- data/README.md +1 -1
- data/lib/google/cloud/dataproc/v1/autoscaling_policies_pb.rb +3 -2
- data/lib/google/cloud/dataproc/v1/autoscaling_policy_service/client.rb +154 -69
- data/lib/google/cloud/dataproc/v1/batch_controller/client.rb +718 -0
- data/lib/google/cloud/dataproc/v1/batch_controller/credentials.rb +51 -0
- data/lib/google/cloud/dataproc/v1/batch_controller/operations.rb +767 -0
- data/lib/google/cloud/dataproc/v1/batch_controller/paths.rb +69 -0
- data/lib/google/cloud/dataproc/v1/batch_controller.rb +50 -0
- data/lib/google/cloud/dataproc/v1/batches_pb.rb +123 -0
- data/lib/google/cloud/dataproc/v1/batches_services_pb.rb +52 -0
- data/lib/google/cloud/dataproc/v1/cluster_controller/client.rb +325 -118
- data/lib/google/cloud/dataproc/v1/cluster_controller/operations.rb +149 -37
- data/lib/google/cloud/dataproc/v1/clusters_pb.rb +9 -2
- data/lib/google/cloud/dataproc/v1/clusters_services_pb.rb +2 -0
- data/lib/google/cloud/dataproc/v1/job_controller/client.rb +244 -104
- data/lib/google/cloud/dataproc/v1/job_controller/operations.rb +149 -37
- data/lib/google/cloud/dataproc/v1/jobs_pb.rb +2 -2
- data/lib/google/cloud/dataproc/v1/operations_pb.rb +18 -3
- data/lib/google/cloud/dataproc/v1/shared_pb.rb +40 -2
- data/lib/google/cloud/dataproc/v1/version.rb +1 -1
- data/lib/google/cloud/dataproc/v1/workflow_template_service/client.rb +219 -95
- data/lib/google/cloud/dataproc/v1/workflow_template_service/operations.rb +149 -37
- data/lib/google/cloud/dataproc/v1/workflow_templates_pb.rb +2 -2
- data/lib/google/cloud/dataproc/v1/workflow_templates_services_pb.rb +1 -2
- data/lib/google/cloud/dataproc/v1.rb +1 -0
- data/proto_docs/google/api/field_behavior.rb +7 -1
- data/proto_docs/google/cloud/dataproc/v1/autoscaling_policies.rb +18 -0
- data/proto_docs/google/cloud/dataproc/v1/batches.rb +339 -0
- data/proto_docs/google/cloud/dataproc/v1/clusters.rb +45 -22
- data/proto_docs/google/cloud/dataproc/v1/jobs.rb +8 -9
- data/proto_docs/google/cloud/dataproc/v1/operations.rb +48 -0
- data/proto_docs/google/cloud/dataproc/v1/shared.rb +117 -1
- data/proto_docs/google/cloud/dataproc/v1/workflow_templates.rb +11 -14
- metadata +12 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 89df0e2a0ac1dd2d7ac88db153a9944695825e95a77e6236c2c31104dfae639a
|
4
|
+
data.tar.gz: 49d4306b2f39e73df7516c9e406d3a174b57c72c4db1c33e71d4160c0bb0d804
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4c074e0cc9460c96da62a9b1061e336d842f31d1f180042638955262307a2d432398a9a00798481b00383269540856dff53fa0cb6d701373272a605121a6eefa
|
7
|
+
data.tar.gz: d39afd0382e2a898768a12973588f228729dd7dcd9dc60ce6a742b240c047e4d20604718e9196689995ab5de6d90b6df8012a2172acc0ccc804ebbd113c1b30a
|
data/AUTHENTICATION.md
CHANGED
@@ -66,11 +66,11 @@ The environment variables that google-cloud-dataproc-v1
|
|
66
66
|
checks for credentials are configured on the service Credentials class (such as
|
67
67
|
{::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Credentials}):
|
68
68
|
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
69
|
+
* `DATAPROC_CREDENTIALS` - Path to JSON file, or JSON contents
|
70
|
+
* `DATAPROC_KEYFILE` - Path to JSON file, or JSON contents
|
71
|
+
* `GOOGLE_CLOUD_CREDENTIALS` - Path to JSON file, or JSON contents
|
72
|
+
* `GOOGLE_CLOUD_KEYFILE` - Path to JSON file, or JSON contents
|
73
|
+
* `GOOGLE_APPLICATION_CREDENTIALS` - Path to JSON file
|
74
74
|
|
75
75
|
```ruby
|
76
76
|
require "google/cloud/dataproc/v1"
|
@@ -82,8 +82,8 @@ client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
|
82
82
|
|
83
83
|
### Configuration
|
84
84
|
|
85
|
-
The **Credentials JSON** can be configured instead of
|
86
|
-
environment
|
85
|
+
The path to the **Credentials JSON** file can be configured instead of storing
|
86
|
+
it in an environment variable. Either on an individual client initialization:
|
87
87
|
|
88
88
|
```ruby
|
89
89
|
require "google/cloud/dataproc/v1"
|
@@ -93,7 +93,7 @@ client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new do
|
|
93
93
|
end
|
94
94
|
```
|
95
95
|
|
96
|
-
Or
|
96
|
+
Or globally for all clients:
|
97
97
|
|
98
98
|
```ruby
|
99
99
|
require "google/cloud/dataproc/v1"
|
data/README.md
CHANGED
@@ -33,7 +33,7 @@ In order to use this library, you first need to go through the following steps:
|
|
33
33
|
require "google/cloud/dataproc/v1"
|
34
34
|
|
35
35
|
client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
36
|
-
request =
|
36
|
+
request = ::Google::Cloud::Dataproc::V1::CreateAutoscalingPolicyRequest.new # (request fields as keyword arguments...)
|
37
37
|
response = client.create_autoscaling_policy request
|
38
38
|
```
|
39
39
|
|
@@ -1,14 +1,14 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/dataproc/v1/autoscaling_policies.proto
|
3
3
|
|
4
|
-
require 'google/protobuf'
|
5
|
-
|
6
4
|
require 'google/api/annotations_pb'
|
7
5
|
require 'google/api/client_pb'
|
8
6
|
require 'google/api/field_behavior_pb'
|
9
7
|
require 'google/api/resource_pb'
|
10
8
|
require 'google/protobuf/duration_pb'
|
11
9
|
require 'google/protobuf/empty_pb'
|
10
|
+
require 'google/protobuf'
|
11
|
+
|
12
12
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
13
13
|
add_file("google/cloud/dataproc/v1/autoscaling_policies.proto", :syntax => :proto3) do
|
14
14
|
add_message "google.cloud.dataproc.v1.AutoscalingPolicy" do
|
@@ -16,6 +16,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
16
16
|
optional :name, :string, 2
|
17
17
|
optional :worker_config, :message, 4, "google.cloud.dataproc.v1.InstanceGroupAutoscalingPolicyConfig"
|
18
18
|
optional :secondary_worker_config, :message, 5, "google.cloud.dataproc.v1.InstanceGroupAutoscalingPolicyConfig"
|
19
|
+
map :labels, :string, :string, 6
|
19
20
|
oneof :algorithm do
|
20
21
|
optional :basic_algorithm, :message, 3, "google.cloud.dataproc.v1.BasicAutoscalingAlgorithm"
|
21
22
|
end
|
@@ -42,13 +42,12 @@ module Google
|
|
42
42
|
# See {::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client::Configuration}
|
43
43
|
# for a description of the configuration fields.
|
44
44
|
#
|
45
|
-
#
|
45
|
+
# @example
|
46
46
|
#
|
47
|
-
#
|
48
|
-
#
|
49
|
-
#
|
50
|
-
#
|
51
|
-
# end
|
47
|
+
# # Modify the configuration for all AutoscalingPolicyService clients
|
48
|
+
# ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.configure do |config|
|
49
|
+
# config.timeout = 10.0
|
50
|
+
# end
|
52
51
|
#
|
53
52
|
# @yield [config] Configure the Client client.
|
54
53
|
# @yieldparam config [Client::Configuration]
|
@@ -70,26 +69,17 @@ module Google
|
|
70
69
|
|
71
70
|
default_config.rpcs.update_autoscaling_policy.timeout = 600.0
|
72
71
|
default_config.rpcs.update_autoscaling_policy.retry_policy = {
|
73
|
-
initial_delay: 0.1,
|
74
|
-
max_delay: 60.0,
|
75
|
-
multiplier: 1.3,
|
76
|
-
retry_codes: [4, 14]
|
72
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
77
73
|
}
|
78
74
|
|
79
75
|
default_config.rpcs.get_autoscaling_policy.timeout = 600.0
|
80
76
|
default_config.rpcs.get_autoscaling_policy.retry_policy = {
|
81
|
-
initial_delay: 0.1,
|
82
|
-
max_delay: 60.0,
|
83
|
-
multiplier: 1.3,
|
84
|
-
retry_codes: [4, 14]
|
77
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
85
78
|
}
|
86
79
|
|
87
80
|
default_config.rpcs.list_autoscaling_policies.timeout = 600.0
|
88
81
|
default_config.rpcs.list_autoscaling_policies.retry_policy = {
|
89
|
-
initial_delay: 0.1,
|
90
|
-
max_delay: 60.0,
|
91
|
-
multiplier: 1.3,
|
92
|
-
retry_codes: [4, 14]
|
82
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
93
83
|
}
|
94
84
|
|
95
85
|
default_config.rpcs.delete_autoscaling_policy.timeout = 600.0
|
@@ -123,19 +113,15 @@ module Google
|
|
123
113
|
##
|
124
114
|
# Create a new AutoscalingPolicyService client object.
|
125
115
|
#
|
126
|
-
#
|
127
|
-
#
|
128
|
-
# To create a new AutoscalingPolicyService client with the default
|
129
|
-
# configuration:
|
130
|
-
#
|
131
|
-
# client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
116
|
+
# @example
|
132
117
|
#
|
133
|
-
#
|
134
|
-
#
|
118
|
+
# # Create a client using the default configuration
|
119
|
+
# client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
135
120
|
#
|
136
|
-
#
|
137
|
-
#
|
138
|
-
#
|
121
|
+
# # Create a client using a custom configuration
|
122
|
+
# client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new do |config|
|
123
|
+
# config.timeout = 10.0
|
124
|
+
# end
|
139
125
|
#
|
140
126
|
# @yield [config] Configure the AutoscalingPolicyService client.
|
141
127
|
# @yieldparam config [Client::Configuration]
|
@@ -155,14 +141,13 @@ module Google
|
|
155
141
|
|
156
142
|
# Create credentials
|
157
143
|
credentials = @config.credentials
|
158
|
-
# Use self-signed JWT if the
|
144
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
159
145
|
# but only if the default endpoint does not have a region prefix.
|
160
|
-
enable_self_signed_jwt = @config.
|
161
|
-
@config.endpoint == Client.configure.endpoint &&
|
146
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
162
147
|
!@config.endpoint.split(".").first.include?("-")
|
163
148
|
credentials ||= Credentials.default scope: @config.scope,
|
164
149
|
enable_self_signed_jwt: enable_self_signed_jwt
|
165
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
150
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
166
151
|
credentials = Credentials.new credentials, scope: @config.scope
|
167
152
|
end
|
168
153
|
@quota_project_id = @config.quota_project
|
@@ -219,6 +204,21 @@ module Google
|
|
219
204
|
#
|
220
205
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
221
206
|
#
|
207
|
+
# @example Basic example
|
208
|
+
# require "google/cloud/dataproc/v1"
|
209
|
+
#
|
210
|
+
# # Create a client object. The client can be reused for multiple calls.
|
211
|
+
# client = Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
212
|
+
#
|
213
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
214
|
+
# request = Google::Cloud::Dataproc::V1::CreateAutoscalingPolicyRequest.new
|
215
|
+
#
|
216
|
+
# # Call the create_autoscaling_policy method.
|
217
|
+
# result = client.create_autoscaling_policy request
|
218
|
+
#
|
219
|
+
# # The returned object is of type Google::Cloud::Dataproc::V1::AutoscalingPolicy.
|
220
|
+
# p result
|
221
|
+
#
|
222
222
|
def create_autoscaling_policy request, options = nil
|
223
223
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
224
224
|
|
@@ -236,16 +236,20 @@ module Google
|
|
236
236
|
gapic_version: ::Google::Cloud::Dataproc::V1::VERSION
|
237
237
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
238
238
|
|
239
|
-
header_params = {
|
240
|
-
|
241
|
-
|
239
|
+
header_params = {}
|
240
|
+
if request.parent
|
241
|
+
header_params["parent"] = request.parent
|
242
|
+
end
|
243
|
+
|
242
244
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
243
245
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
244
246
|
|
245
247
|
options.apply_defaults timeout: @config.rpcs.create_autoscaling_policy.timeout,
|
246
248
|
metadata: metadata,
|
247
249
|
retry_policy: @config.rpcs.create_autoscaling_policy.retry_policy
|
248
|
-
|
250
|
+
|
251
|
+
options.apply_defaults timeout: @config.timeout,
|
252
|
+
metadata: @config.metadata,
|
249
253
|
retry_policy: @config.retry_policy
|
250
254
|
|
251
255
|
@autoscaling_policy_service_stub.call_rpc :create_autoscaling_policy, request, options: options do |response, operation|
|
@@ -288,6 +292,21 @@ module Google
|
|
288
292
|
#
|
289
293
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
290
294
|
#
|
295
|
+
# @example Basic example
|
296
|
+
# require "google/cloud/dataproc/v1"
|
297
|
+
#
|
298
|
+
# # Create a client object. The client can be reused for multiple calls.
|
299
|
+
# client = Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
300
|
+
#
|
301
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
302
|
+
# request = Google::Cloud::Dataproc::V1::UpdateAutoscalingPolicyRequest.new
|
303
|
+
#
|
304
|
+
# # Call the update_autoscaling_policy method.
|
305
|
+
# result = client.update_autoscaling_policy request
|
306
|
+
#
|
307
|
+
# # The returned object is of type Google::Cloud::Dataproc::V1::AutoscalingPolicy.
|
308
|
+
# p result
|
309
|
+
#
|
291
310
|
def update_autoscaling_policy request, options = nil
|
292
311
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
293
312
|
|
@@ -305,16 +324,20 @@ module Google
|
|
305
324
|
gapic_version: ::Google::Cloud::Dataproc::V1::VERSION
|
306
325
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
307
326
|
|
308
|
-
header_params = {
|
309
|
-
|
310
|
-
|
327
|
+
header_params = {}
|
328
|
+
if request.policy&.name
|
329
|
+
header_params["policy.name"] = request.policy.name
|
330
|
+
end
|
331
|
+
|
311
332
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
312
333
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
313
334
|
|
314
335
|
options.apply_defaults timeout: @config.rpcs.update_autoscaling_policy.timeout,
|
315
336
|
metadata: metadata,
|
316
337
|
retry_policy: @config.rpcs.update_autoscaling_policy.retry_policy
|
317
|
-
|
338
|
+
|
339
|
+
options.apply_defaults timeout: @config.timeout,
|
340
|
+
metadata: @config.metadata,
|
318
341
|
retry_policy: @config.retry_policy
|
319
342
|
|
320
343
|
@autoscaling_policy_service_stub.call_rpc :update_autoscaling_policy, request, options: options do |response, operation|
|
@@ -363,6 +386,21 @@ module Google
|
|
363
386
|
#
|
364
387
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
365
388
|
#
|
389
|
+
# @example Basic example
|
390
|
+
# require "google/cloud/dataproc/v1"
|
391
|
+
#
|
392
|
+
# # Create a client object. The client can be reused for multiple calls.
|
393
|
+
# client = Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
394
|
+
#
|
395
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
396
|
+
# request = Google::Cloud::Dataproc::V1::GetAutoscalingPolicyRequest.new
|
397
|
+
#
|
398
|
+
# # Call the get_autoscaling_policy method.
|
399
|
+
# result = client.get_autoscaling_policy request
|
400
|
+
#
|
401
|
+
# # The returned object is of type Google::Cloud::Dataproc::V1::AutoscalingPolicy.
|
402
|
+
# p result
|
403
|
+
#
|
366
404
|
def get_autoscaling_policy request, options = nil
|
367
405
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
368
406
|
|
@@ -380,16 +418,20 @@ module Google
|
|
380
418
|
gapic_version: ::Google::Cloud::Dataproc::V1::VERSION
|
381
419
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
382
420
|
|
383
|
-
header_params = {
|
384
|
-
|
385
|
-
|
421
|
+
header_params = {}
|
422
|
+
if request.name
|
423
|
+
header_params["name"] = request.name
|
424
|
+
end
|
425
|
+
|
386
426
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
387
427
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
388
428
|
|
389
429
|
options.apply_defaults timeout: @config.rpcs.get_autoscaling_policy.timeout,
|
390
430
|
metadata: metadata,
|
391
431
|
retry_policy: @config.rpcs.get_autoscaling_policy.retry_policy
|
392
|
-
|
432
|
+
|
433
|
+
options.apply_defaults timeout: @config.timeout,
|
434
|
+
metadata: @config.metadata,
|
393
435
|
retry_policy: @config.retry_policy
|
394
436
|
|
395
437
|
@autoscaling_policy_service_stub.call_rpc :get_autoscaling_policy, request, options: options do |response, operation|
|
@@ -444,6 +486,27 @@ module Google
|
|
444
486
|
#
|
445
487
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
446
488
|
#
|
489
|
+
# @example Basic example
|
490
|
+
# require "google/cloud/dataproc/v1"
|
491
|
+
#
|
492
|
+
# # Create a client object. The client can be reused for multiple calls.
|
493
|
+
# client = Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
494
|
+
#
|
495
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
496
|
+
# request = Google::Cloud::Dataproc::V1::ListAutoscalingPoliciesRequest.new
|
497
|
+
#
|
498
|
+
# # Call the list_autoscaling_policies method.
|
499
|
+
# result = client.list_autoscaling_policies request
|
500
|
+
#
|
501
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
502
|
+
# # iterate over all elements by calling #each, and the enumerable
|
503
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
504
|
+
# # methods are also available for managing paging directly.
|
505
|
+
# result.each do |response|
|
506
|
+
# # Each element is of type ::Google::Cloud::Dataproc::V1::AutoscalingPolicy.
|
507
|
+
# p response
|
508
|
+
# end
|
509
|
+
#
|
447
510
|
def list_autoscaling_policies request, options = nil
|
448
511
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
449
512
|
|
@@ -461,16 +524,20 @@ module Google
|
|
461
524
|
gapic_version: ::Google::Cloud::Dataproc::V1::VERSION
|
462
525
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
463
526
|
|
464
|
-
header_params = {
|
465
|
-
|
466
|
-
|
527
|
+
header_params = {}
|
528
|
+
if request.parent
|
529
|
+
header_params["parent"] = request.parent
|
530
|
+
end
|
531
|
+
|
467
532
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
468
533
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
469
534
|
|
470
535
|
options.apply_defaults timeout: @config.rpcs.list_autoscaling_policies.timeout,
|
471
536
|
metadata: metadata,
|
472
537
|
retry_policy: @config.rpcs.list_autoscaling_policies.retry_policy
|
473
|
-
|
538
|
+
|
539
|
+
options.apply_defaults timeout: @config.timeout,
|
540
|
+
metadata: @config.metadata,
|
474
541
|
retry_policy: @config.retry_policy
|
475
542
|
|
476
543
|
@autoscaling_policy_service_stub.call_rpc :list_autoscaling_policies, request, options: options do |response, operation|
|
@@ -521,6 +588,21 @@ module Google
|
|
521
588
|
#
|
522
589
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
523
590
|
#
|
591
|
+
# @example Basic example
|
592
|
+
# require "google/cloud/dataproc/v1"
|
593
|
+
#
|
594
|
+
# # Create a client object. The client can be reused for multiple calls.
|
595
|
+
# client = Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new
|
596
|
+
#
|
597
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
598
|
+
# request = Google::Cloud::Dataproc::V1::DeleteAutoscalingPolicyRequest.new
|
599
|
+
#
|
600
|
+
# # Call the delete_autoscaling_policy method.
|
601
|
+
# result = client.delete_autoscaling_policy request
|
602
|
+
#
|
603
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
604
|
+
# p result
|
605
|
+
#
|
524
606
|
def delete_autoscaling_policy request, options = nil
|
525
607
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
526
608
|
|
@@ -538,16 +620,20 @@ module Google
|
|
538
620
|
gapic_version: ::Google::Cloud::Dataproc::V1::VERSION
|
539
621
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
540
622
|
|
541
|
-
header_params = {
|
542
|
-
|
543
|
-
|
623
|
+
header_params = {}
|
624
|
+
if request.name
|
625
|
+
header_params["name"] = request.name
|
626
|
+
end
|
627
|
+
|
544
628
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
545
629
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
546
630
|
|
547
631
|
options.apply_defaults timeout: @config.rpcs.delete_autoscaling_policy.timeout,
|
548
632
|
metadata: metadata,
|
549
633
|
retry_policy: @config.rpcs.delete_autoscaling_policy.retry_policy
|
550
|
-
|
634
|
+
|
635
|
+
options.apply_defaults timeout: @config.timeout,
|
636
|
+
metadata: @config.metadata,
|
551
637
|
retry_policy: @config.retry_policy
|
552
638
|
|
553
639
|
@autoscaling_policy_service_stub.call_rpc :delete_autoscaling_policy, request, options: options do |response, operation|
|
@@ -571,22 +657,21 @@ module Google
|
|
571
657
|
# Configuration can be applied globally to all clients, or to a single client
|
572
658
|
# on construction.
|
573
659
|
#
|
574
|
-
#
|
575
|
-
#
|
576
|
-
#
|
577
|
-
# to 20 seconds,
|
578
|
-
#
|
579
|
-
#
|
580
|
-
#
|
581
|
-
#
|
582
|
-
#
|
583
|
-
#
|
584
|
-
#
|
585
|
-
#
|
586
|
-
#
|
587
|
-
#
|
588
|
-
#
|
589
|
-
# end
|
660
|
+
# @example
|
661
|
+
#
|
662
|
+
# # Modify the global config, setting the timeout for
|
663
|
+
# # create_autoscaling_policy to 20 seconds,
|
664
|
+
# # and all remaining timeouts to 10 seconds.
|
665
|
+
# ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.configure do |config|
|
666
|
+
# config.timeout = 10.0
|
667
|
+
# config.rpcs.create_autoscaling_policy.timeout = 20.0
|
668
|
+
# end
|
669
|
+
#
|
670
|
+
# # Apply the above configuration only to a new client.
|
671
|
+
# client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Client.new do |config|
|
672
|
+
# config.timeout = 10.0
|
673
|
+
# config.rpcs.create_autoscaling_policy.timeout = 20.0
|
674
|
+
# end
|
590
675
|
#
|
591
676
|
# @!attribute [rw] endpoint
|
592
677
|
# The hostname or hostname:port of the service endpoint.
|