google-cloud-compute-v1 2.5.0 → 2.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/addresses/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +277 -1
- data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +182 -0
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +196 -3
- data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +120 -0
- data/lib/google/cloud/compute/v1/compute_pb.rb +79 -1
- data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +2 -2
- data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/images/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +7 -6
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +5 -4
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +109 -4
- data/lib/google/cloud/compute/v1/instances/rest/service_stub.rb +62 -0
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +94 -2
- data/lib/google/cloud/compute/v1/interconnects/rest/service_stub.rb +60 -0
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/network_attachments/rest/client.rb +108 -3
- data/lib/google/cloud/compute/v1/network_attachments/rest/service_stub.rb +62 -0
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/client.rb +3 -2
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +5 -4
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +2 -2
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +5 -4
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/node_types/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +2 -2
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +202 -4
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/service_stub.rb +120 -0
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +208 -3
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/service_stub.rb +122 -0
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +301 -1
- data/lib/google/cloud/compute/v1/region_backend_services/rest/service_stub.rb +184 -0
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +4 -4
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +2 -2
- data/lib/google/cloud/compute/v1/region_instance_templates/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +314 -4
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/service_stub.rb +185 -0
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_security_policies/rest/client.rb +417 -5
- data/lib/google/cloud/compute/v1/region_security_policies/rest/service_stub.rb +246 -0
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/client.rb +2 -2
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/regions/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/rest.rb +1 -0
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +101 -4
- data/lib/google/cloud/compute/v1/routers/rest/service_stub.rb +61 -0
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +11 -6
- data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/snapshot_settings_service/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/client.rb +480 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/service_stub.rb +167 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service.rb +47 -0
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +5 -4
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +5 -4
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +108 -3
- data/lib/google/cloud/compute/v1/target_instances/rest/service_stub.rb +62 -0
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +108 -3
- data/lib/google/cloud/compute/v1/target_pools/rest/service_stub.rb +62 -0
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +4 -3
- data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1/zones/rest/client.rb +1 -1
- data/lib/google/cloud/compute/v1.rb +1 -0
- data/proto_docs/google/api/client.rb +13 -0
- data/proto_docs/google/cloud/compute/v1/compute.rb +1654 -196
- data/proto_docs/google/protobuf/any.rb +144 -0
- metadata +8 -2
@@ -192,6 +192,44 @@ module Google
|
|
192
192
|
result
|
193
193
|
end
|
194
194
|
|
195
|
+
##
|
196
|
+
# Baseline implementation for the get_iam_policy REST call
|
197
|
+
#
|
198
|
+
# @param request_pb [::Google::Cloud::Compute::V1::GetIamPolicyBackendBucketRequest]
|
199
|
+
# A request object representing the call parameters. Required.
|
200
|
+
# @param options [::Gapic::CallOptions]
|
201
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
202
|
+
#
|
203
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
204
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Policy]
|
205
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
206
|
+
#
|
207
|
+
# @return [::Google::Cloud::Compute::V1::Policy]
|
208
|
+
# A result object deserialized from the server's reply
|
209
|
+
def get_iam_policy request_pb, options = nil
|
210
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
211
|
+
|
212
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_iam_policy_request request_pb
|
213
|
+
query_string_params = if query_string_params.any?
|
214
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
215
|
+
else
|
216
|
+
{}
|
217
|
+
end
|
218
|
+
|
219
|
+
response = @client_stub.make_http_request(
|
220
|
+
verb,
|
221
|
+
uri: uri,
|
222
|
+
body: body || "",
|
223
|
+
params: query_string_params,
|
224
|
+
options: options
|
225
|
+
)
|
226
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
227
|
+
result = ::Google::Cloud::Compute::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
228
|
+
|
229
|
+
yield result, operation if block_given?
|
230
|
+
result
|
231
|
+
end
|
232
|
+
|
195
233
|
##
|
196
234
|
# Baseline implementation for the insert REST call
|
197
235
|
#
|
@@ -344,6 +382,82 @@ module Google
|
|
344
382
|
result
|
345
383
|
end
|
346
384
|
|
385
|
+
##
|
386
|
+
# Baseline implementation for the set_iam_policy REST call
|
387
|
+
#
|
388
|
+
# @param request_pb [::Google::Cloud::Compute::V1::SetIamPolicyBackendBucketRequest]
|
389
|
+
# A request object representing the call parameters. Required.
|
390
|
+
# @param options [::Gapic::CallOptions]
|
391
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
392
|
+
#
|
393
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
394
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Policy]
|
395
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
396
|
+
#
|
397
|
+
# @return [::Google::Cloud::Compute::V1::Policy]
|
398
|
+
# A result object deserialized from the server's reply
|
399
|
+
def set_iam_policy request_pb, options = nil
|
400
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
401
|
+
|
402
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_set_iam_policy_request request_pb
|
403
|
+
query_string_params = if query_string_params.any?
|
404
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
405
|
+
else
|
406
|
+
{}
|
407
|
+
end
|
408
|
+
|
409
|
+
response = @client_stub.make_http_request(
|
410
|
+
verb,
|
411
|
+
uri: uri,
|
412
|
+
body: body || "",
|
413
|
+
params: query_string_params,
|
414
|
+
options: options
|
415
|
+
)
|
416
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
417
|
+
result = ::Google::Cloud::Compute::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
418
|
+
|
419
|
+
yield result, operation if block_given?
|
420
|
+
result
|
421
|
+
end
|
422
|
+
|
423
|
+
##
|
424
|
+
# Baseline implementation for the test_iam_permissions REST call
|
425
|
+
#
|
426
|
+
# @param request_pb [::Google::Cloud::Compute::V1::TestIamPermissionsBackendBucketRequest]
|
427
|
+
# A request object representing the call parameters. Required.
|
428
|
+
# @param options [::Gapic::CallOptions]
|
429
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
430
|
+
#
|
431
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
432
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
433
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
434
|
+
#
|
435
|
+
# @return [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
436
|
+
# A result object deserialized from the server's reply
|
437
|
+
def test_iam_permissions request_pb, options = nil
|
438
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
439
|
+
|
440
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_test_iam_permissions_request request_pb
|
441
|
+
query_string_params = if query_string_params.any?
|
442
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
443
|
+
else
|
444
|
+
{}
|
445
|
+
end
|
446
|
+
|
447
|
+
response = @client_stub.make_http_request(
|
448
|
+
verb,
|
449
|
+
uri: uri,
|
450
|
+
body: body || "",
|
451
|
+
params: query_string_params,
|
452
|
+
options: options
|
453
|
+
)
|
454
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
455
|
+
result = ::Google::Cloud::Compute::V1::TestPermissionsResponse.decode_json response.body, ignore_unknown_fields: true
|
456
|
+
|
457
|
+
yield result, operation if block_given?
|
458
|
+
result
|
459
|
+
end
|
460
|
+
|
347
461
|
##
|
348
462
|
# Baseline implementation for the update REST call
|
349
463
|
#
|
@@ -471,6 +585,28 @@ module Google
|
|
471
585
|
transcoder.transcode request_pb
|
472
586
|
end
|
473
587
|
|
588
|
+
##
|
589
|
+
# @private
|
590
|
+
#
|
591
|
+
# GRPC transcoding helper method for the get_iam_policy REST call
|
592
|
+
#
|
593
|
+
# @param request_pb [::Google::Cloud::Compute::V1::GetIamPolicyBackendBucketRequest]
|
594
|
+
# A request object representing the call parameters. Required.
|
595
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
596
|
+
# Uri, Body, Query string parameters
|
597
|
+
def self.transcode_get_iam_policy_request request_pb
|
598
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
599
|
+
.with_bindings(
|
600
|
+
uri_method: :get,
|
601
|
+
uri_template: "/compute/v1/projects/{project}/global/backendBuckets/{resource}/getIamPolicy",
|
602
|
+
matches: [
|
603
|
+
["project", %r{^[^/]+/?$}, false],
|
604
|
+
["resource", %r{^[^/]+/?$}, false]
|
605
|
+
]
|
606
|
+
)
|
607
|
+
transcoder.transcode request_pb
|
608
|
+
end
|
609
|
+
|
474
610
|
##
|
475
611
|
# @private
|
476
612
|
#
|
@@ -560,6 +696,52 @@ module Google
|
|
560
696
|
transcoder.transcode request_pb
|
561
697
|
end
|
562
698
|
|
699
|
+
##
|
700
|
+
# @private
|
701
|
+
#
|
702
|
+
# GRPC transcoding helper method for the set_iam_policy REST call
|
703
|
+
#
|
704
|
+
# @param request_pb [::Google::Cloud::Compute::V1::SetIamPolicyBackendBucketRequest]
|
705
|
+
# A request object representing the call parameters. Required.
|
706
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
707
|
+
# Uri, Body, Query string parameters
|
708
|
+
def self.transcode_set_iam_policy_request request_pb
|
709
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
710
|
+
.with_bindings(
|
711
|
+
uri_method: :post,
|
712
|
+
uri_template: "/compute/v1/projects/{project}/global/backendBuckets/{resource}/setIamPolicy",
|
713
|
+
body: "global_set_policy_request_resource",
|
714
|
+
matches: [
|
715
|
+
["project", %r{^[^/]+/?$}, false],
|
716
|
+
["resource", %r{^[^/]+/?$}, false]
|
717
|
+
]
|
718
|
+
)
|
719
|
+
transcoder.transcode request_pb
|
720
|
+
end
|
721
|
+
|
722
|
+
##
|
723
|
+
# @private
|
724
|
+
#
|
725
|
+
# GRPC transcoding helper method for the test_iam_permissions REST call
|
726
|
+
#
|
727
|
+
# @param request_pb [::Google::Cloud::Compute::V1::TestIamPermissionsBackendBucketRequest]
|
728
|
+
# A request object representing the call parameters. Required.
|
729
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
730
|
+
# Uri, Body, Query string parameters
|
731
|
+
def self.transcode_test_iam_permissions_request request_pb
|
732
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
733
|
+
.with_bindings(
|
734
|
+
uri_method: :post,
|
735
|
+
uri_template: "/compute/v1/projects/{project}/global/backendBuckets/{resource}/testIamPermissions",
|
736
|
+
body: "test_permissions_request_resource",
|
737
|
+
matches: [
|
738
|
+
["project", %r{^[^/]+/?$}, false],
|
739
|
+
["resource", %r{^[^/]+/?$}, false]
|
740
|
+
]
|
741
|
+
)
|
742
|
+
transcoder.transcode request_pb
|
743
|
+
end
|
744
|
+
|
563
745
|
##
|
564
746
|
# @private
|
565
747
|
#
|
@@ -95,6 +95,11 @@ module Google
|
|
95
95
|
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
96
96
|
}
|
97
97
|
|
98
|
+
default_config.rpcs.list_usable.timeout = 600.0
|
99
|
+
default_config.rpcs.list_usable.retry_policy = {
|
100
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
101
|
+
}
|
102
|
+
|
98
103
|
default_config.rpcs.patch.timeout = 600.0
|
99
104
|
|
100
105
|
default_config.rpcs.set_edge_security_policy.timeout = 600.0
|
@@ -103,6 +108,8 @@ module Google
|
|
103
108
|
|
104
109
|
default_config.rpcs.set_security_policy.timeout = 600.0
|
105
110
|
|
111
|
+
default_config.rpcs.test_iam_permissions.timeout = 600.0
|
112
|
+
|
106
113
|
default_config.rpcs.update.timeout = 600.0
|
107
114
|
|
108
115
|
default_config
|
@@ -292,13 +299,13 @@ module Google
|
|
292
299
|
# @param options [::Gapic::CallOptions, ::Hash]
|
293
300
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
294
301
|
#
|
295
|
-
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil)
|
302
|
+
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil, service_project_number: nil)
|
296
303
|
# Pass arguments to `aggregated_list` via keyword arguments. Note that at
|
297
304
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
298
305
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
299
306
|
#
|
300
307
|
# @param filter [::String]
|
301
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
308
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
302
309
|
# @param include_all_scopes [::Boolean]
|
303
310
|
# Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.
|
304
311
|
# @param max_results [::Integer]
|
@@ -311,6 +318,7 @@ module Google
|
|
311
318
|
# Name of the project scoping this request.
|
312
319
|
# @param return_partial_success [::Boolean]
|
313
320
|
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
321
|
+
# @param service_project_number [::Integer]
|
314
322
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
315
323
|
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::String, ::Google::Cloud::Compute::V1::BackendServicesScopedList>]
|
316
324
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -904,7 +912,7 @@ module Google
|
|
904
912
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
905
913
|
#
|
906
914
|
# @param filter [::String]
|
907
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
915
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
908
916
|
# @param max_results [::Integer]
|
909
917
|
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
910
918
|
# @param order_by [::String]
|
@@ -974,6 +982,95 @@ module Google
|
|
974
982
|
raise ::Google::Cloud::Error.from_error(e)
|
975
983
|
end
|
976
984
|
|
985
|
+
##
|
986
|
+
# Retrieves an aggregated list of all usable backend services in the specified project.
|
987
|
+
#
|
988
|
+
# @overload list_usable(request, options = nil)
|
989
|
+
# Pass arguments to `list_usable` via a request object, either of type
|
990
|
+
# {::Google::Cloud::Compute::V1::ListUsableBackendServicesRequest} or an equivalent Hash.
|
991
|
+
#
|
992
|
+
# @param request [::Google::Cloud::Compute::V1::ListUsableBackendServicesRequest, ::Hash]
|
993
|
+
# A request object representing the call parameters. Required. To specify no
|
994
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
995
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
996
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
997
|
+
#
|
998
|
+
# @overload list_usable(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil)
|
999
|
+
# Pass arguments to `list_usable` via keyword arguments. Note that at
|
1000
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1001
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1002
|
+
#
|
1003
|
+
# @param filter [::String]
|
1004
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
1005
|
+
# @param max_results [::Integer]
|
1006
|
+
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
1007
|
+
# @param order_by [::String]
|
1008
|
+
# Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using `orderBy="creationTimestamp desc"`. This sorts results based on the `creationTimestamp` field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by `name` or `creationTimestamp desc` is supported.
|
1009
|
+
# @param page_token [::String]
|
1010
|
+
# Specifies a page token to use. Set `pageToken` to the `nextPageToken` returned by a previous list request to get the next page of results.
|
1011
|
+
# @param project [::String]
|
1012
|
+
# Project ID for this request.
|
1013
|
+
# @param return_partial_success [::Boolean]
|
1014
|
+
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
1015
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1016
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendService>]
|
1017
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1018
|
+
#
|
1019
|
+
# @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::BackendService>]
|
1020
|
+
#
|
1021
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1022
|
+
#
|
1023
|
+
# @example Basic example
|
1024
|
+
# require "google/cloud/compute/v1"
|
1025
|
+
#
|
1026
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1027
|
+
# client = Google::Cloud::Compute::V1::BackendServices::Rest::Client.new
|
1028
|
+
#
|
1029
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1030
|
+
# request = Google::Cloud::Compute::V1::ListUsableBackendServicesRequest.new
|
1031
|
+
#
|
1032
|
+
# # Call the list_usable method.
|
1033
|
+
# result = client.list_usable request
|
1034
|
+
#
|
1035
|
+
# # The returned object is of type Google::Cloud::Compute::V1::BackendServiceListUsable.
|
1036
|
+
# p result
|
1037
|
+
#
|
1038
|
+
def list_usable request, options = nil
|
1039
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1040
|
+
|
1041
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::ListUsableBackendServicesRequest
|
1042
|
+
|
1043
|
+
# Converts hash and nil to an options object
|
1044
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1045
|
+
|
1046
|
+
# Customize the options with defaults
|
1047
|
+
call_metadata = @config.rpcs.list_usable.metadata.to_h
|
1048
|
+
|
1049
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1050
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1051
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1052
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
1053
|
+
transports_version_send: [:rest]
|
1054
|
+
|
1055
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1056
|
+
|
1057
|
+
options.apply_defaults timeout: @config.rpcs.list_usable.timeout,
|
1058
|
+
metadata: call_metadata,
|
1059
|
+
retry_policy: @config.rpcs.list_usable.retry_policy
|
1060
|
+
|
1061
|
+
options.apply_defaults timeout: @config.timeout,
|
1062
|
+
metadata: @config.metadata,
|
1063
|
+
retry_policy: @config.retry_policy
|
1064
|
+
|
1065
|
+
@backend_services_stub.list_usable request, options do |result, operation|
|
1066
|
+
result = ::Gapic::Rest::PagedEnumerable.new @backend_services_stub, :list_usable, "items", request, result, options
|
1067
|
+
yield result, operation if block_given?
|
1068
|
+
return result
|
1069
|
+
end
|
1070
|
+
rescue ::Gapic::Rest::Error => e
|
1071
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1072
|
+
end
|
1073
|
+
|
977
1074
|
##
|
978
1075
|
# Patches the specified BackendService resource with the data included in the request. For more information, see Backend services overview. This method supports PATCH semantics and uses the JSON merge patch format and processing rules.
|
979
1076
|
#
|
@@ -1332,6 +1429,88 @@ module Google
|
|
1332
1429
|
raise ::Google::Cloud::Error.from_error(e)
|
1333
1430
|
end
|
1334
1431
|
|
1432
|
+
##
|
1433
|
+
# Returns permissions that a caller has on the specified resource.
|
1434
|
+
#
|
1435
|
+
# @overload test_iam_permissions(request, options = nil)
|
1436
|
+
# Pass arguments to `test_iam_permissions` via a request object, either of type
|
1437
|
+
# {::Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest} or an equivalent Hash.
|
1438
|
+
#
|
1439
|
+
# @param request [::Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest, ::Hash]
|
1440
|
+
# A request object representing the call parameters. Required. To specify no
|
1441
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1442
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1443
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1444
|
+
#
|
1445
|
+
# @overload test_iam_permissions(project: nil, resource: nil, test_permissions_request_resource: nil)
|
1446
|
+
# Pass arguments to `test_iam_permissions` via keyword arguments. Note that at
|
1447
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1448
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1449
|
+
#
|
1450
|
+
# @param project [::String]
|
1451
|
+
# Project ID for this request.
|
1452
|
+
# @param resource [::String]
|
1453
|
+
# Name or id of the resource for this request.
|
1454
|
+
# @param test_permissions_request_resource [::Google::Cloud::Compute::V1::TestPermissionsRequest, ::Hash]
|
1455
|
+
# The body resource for this request
|
1456
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1457
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
1458
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1459
|
+
#
|
1460
|
+
# @return [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
1461
|
+
#
|
1462
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1463
|
+
#
|
1464
|
+
# @example Basic example
|
1465
|
+
# require "google/cloud/compute/v1"
|
1466
|
+
#
|
1467
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1468
|
+
# client = Google::Cloud::Compute::V1::BackendServices::Rest::Client.new
|
1469
|
+
#
|
1470
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1471
|
+
# request = Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest.new
|
1472
|
+
#
|
1473
|
+
# # Call the test_iam_permissions method.
|
1474
|
+
# result = client.test_iam_permissions request
|
1475
|
+
#
|
1476
|
+
# # The returned object is of type Google::Cloud::Compute::V1::TestPermissionsResponse.
|
1477
|
+
# p result
|
1478
|
+
#
|
1479
|
+
def test_iam_permissions request, options = nil
|
1480
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1481
|
+
|
1482
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest
|
1483
|
+
|
1484
|
+
# Converts hash and nil to an options object
|
1485
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1486
|
+
|
1487
|
+
# Customize the options with defaults
|
1488
|
+
call_metadata = @config.rpcs.test_iam_permissions.metadata.to_h
|
1489
|
+
|
1490
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1491
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1492
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1493
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
1494
|
+
transports_version_send: [:rest]
|
1495
|
+
|
1496
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1497
|
+
|
1498
|
+
options.apply_defaults timeout: @config.rpcs.test_iam_permissions.timeout,
|
1499
|
+
metadata: call_metadata,
|
1500
|
+
retry_policy: @config.rpcs.test_iam_permissions.retry_policy
|
1501
|
+
|
1502
|
+
options.apply_defaults timeout: @config.timeout,
|
1503
|
+
metadata: @config.metadata,
|
1504
|
+
retry_policy: @config.retry_policy
|
1505
|
+
|
1506
|
+
@backend_services_stub.test_iam_permissions request, options do |result, operation|
|
1507
|
+
yield result, operation if block_given?
|
1508
|
+
return result
|
1509
|
+
end
|
1510
|
+
rescue ::Gapic::Rest::Error => e
|
1511
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1512
|
+
end
|
1513
|
+
|
1335
1514
|
##
|
1336
1515
|
# Updates the specified BackendService resource with the data included in the request. For more information, see Backend services overview.
|
1337
1516
|
#
|
@@ -1595,6 +1774,11 @@ module Google
|
|
1595
1774
|
#
|
1596
1775
|
attr_reader :list
|
1597
1776
|
##
|
1777
|
+
# RPC-specific configuration for `list_usable`
|
1778
|
+
# @return [::Gapic::Config::Method]
|
1779
|
+
#
|
1780
|
+
attr_reader :list_usable
|
1781
|
+
##
|
1598
1782
|
# RPC-specific configuration for `patch`
|
1599
1783
|
# @return [::Gapic::Config::Method]
|
1600
1784
|
#
|
@@ -1615,6 +1799,11 @@ module Google
|
|
1615
1799
|
#
|
1616
1800
|
attr_reader :set_security_policy
|
1617
1801
|
##
|
1802
|
+
# RPC-specific configuration for `test_iam_permissions`
|
1803
|
+
# @return [::Gapic::Config::Method]
|
1804
|
+
#
|
1805
|
+
attr_reader :test_iam_permissions
|
1806
|
+
##
|
1618
1807
|
# RPC-specific configuration for `update`
|
1619
1808
|
# @return [::Gapic::Config::Method]
|
1620
1809
|
#
|
@@ -1640,6 +1829,8 @@ module Google
|
|
1640
1829
|
@insert = ::Gapic::Config::Method.new insert_config
|
1641
1830
|
list_config = parent_rpcs.list if parent_rpcs.respond_to? :list
|
1642
1831
|
@list = ::Gapic::Config::Method.new list_config
|
1832
|
+
list_usable_config = parent_rpcs.list_usable if parent_rpcs.respond_to? :list_usable
|
1833
|
+
@list_usable = ::Gapic::Config::Method.new list_usable_config
|
1643
1834
|
patch_config = parent_rpcs.patch if parent_rpcs.respond_to? :patch
|
1644
1835
|
@patch = ::Gapic::Config::Method.new patch_config
|
1645
1836
|
set_edge_security_policy_config = parent_rpcs.set_edge_security_policy if parent_rpcs.respond_to? :set_edge_security_policy
|
@@ -1648,6 +1839,8 @@ module Google
|
|
1648
1839
|
@set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
|
1649
1840
|
set_security_policy_config = parent_rpcs.set_security_policy if parent_rpcs.respond_to? :set_security_policy
|
1650
1841
|
@set_security_policy = ::Gapic::Config::Method.new set_security_policy_config
|
1842
|
+
test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
|
1843
|
+
@test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
|
1651
1844
|
update_config = parent_rpcs.update if parent_rpcs.respond_to? :update
|
1652
1845
|
@update = ::Gapic::Config::Method.new update_config
|
1653
1846
|
|
@@ -382,6 +382,44 @@ module Google
|
|
382
382
|
result
|
383
383
|
end
|
384
384
|
|
385
|
+
##
|
386
|
+
# Baseline implementation for the list_usable REST call
|
387
|
+
#
|
388
|
+
# @param request_pb [::Google::Cloud::Compute::V1::ListUsableBackendServicesRequest]
|
389
|
+
# A request object representing the call parameters. Required.
|
390
|
+
# @param options [::Gapic::CallOptions]
|
391
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
392
|
+
#
|
393
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
394
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::BackendServiceListUsable]
|
395
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
396
|
+
#
|
397
|
+
# @return [::Google::Cloud::Compute::V1::BackendServiceListUsable]
|
398
|
+
# A result object deserialized from the server's reply
|
399
|
+
def list_usable request_pb, options = nil
|
400
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
401
|
+
|
402
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_usable_request request_pb
|
403
|
+
query_string_params = if query_string_params.any?
|
404
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
405
|
+
else
|
406
|
+
{}
|
407
|
+
end
|
408
|
+
|
409
|
+
response = @client_stub.make_http_request(
|
410
|
+
verb,
|
411
|
+
uri: uri,
|
412
|
+
body: body || "",
|
413
|
+
params: query_string_params,
|
414
|
+
options: options
|
415
|
+
)
|
416
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
417
|
+
result = ::Google::Cloud::Compute::V1::BackendServiceListUsable.decode_json response.body, ignore_unknown_fields: true
|
418
|
+
|
419
|
+
yield result, operation if block_given?
|
420
|
+
result
|
421
|
+
end
|
422
|
+
|
385
423
|
##
|
386
424
|
# Baseline implementation for the patch REST call
|
387
425
|
#
|
@@ -534,6 +572,44 @@ module Google
|
|
534
572
|
result
|
535
573
|
end
|
536
574
|
|
575
|
+
##
|
576
|
+
# Baseline implementation for the test_iam_permissions REST call
|
577
|
+
#
|
578
|
+
# @param request_pb [::Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest]
|
579
|
+
# A request object representing the call parameters. Required.
|
580
|
+
# @param options [::Gapic::CallOptions]
|
581
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
582
|
+
#
|
583
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
584
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
585
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
586
|
+
#
|
587
|
+
# @return [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
588
|
+
# A result object deserialized from the server's reply
|
589
|
+
def test_iam_permissions request_pb, options = nil
|
590
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
591
|
+
|
592
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_test_iam_permissions_request request_pb
|
593
|
+
query_string_params = if query_string_params.any?
|
594
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
595
|
+
else
|
596
|
+
{}
|
597
|
+
end
|
598
|
+
|
599
|
+
response = @client_stub.make_http_request(
|
600
|
+
verb,
|
601
|
+
uri: uri,
|
602
|
+
body: body || "",
|
603
|
+
params: query_string_params,
|
604
|
+
options: options
|
605
|
+
)
|
606
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
607
|
+
result = ::Google::Cloud::Compute::V1::TestPermissionsResponse.decode_json response.body, ignore_unknown_fields: true
|
608
|
+
|
609
|
+
yield result, operation if block_given?
|
610
|
+
result
|
611
|
+
end
|
612
|
+
|
537
613
|
##
|
538
614
|
# Baseline implementation for the update REST call
|
539
615
|
#
|
@@ -770,6 +846,27 @@ module Google
|
|
770
846
|
transcoder.transcode request_pb
|
771
847
|
end
|
772
848
|
|
849
|
+
##
|
850
|
+
# @private
|
851
|
+
#
|
852
|
+
# GRPC transcoding helper method for the list_usable REST call
|
853
|
+
#
|
854
|
+
# @param request_pb [::Google::Cloud::Compute::V1::ListUsableBackendServicesRequest]
|
855
|
+
# A request object representing the call parameters. Required.
|
856
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
857
|
+
# Uri, Body, Query string parameters
|
858
|
+
def self.transcode_list_usable_request request_pb
|
859
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
860
|
+
.with_bindings(
|
861
|
+
uri_method: :get,
|
862
|
+
uri_template: "/compute/v1/projects/{project}/global/backendServices/listUsable",
|
863
|
+
matches: [
|
864
|
+
["project", %r{^[^/]+/?$}, false]
|
865
|
+
]
|
866
|
+
)
|
867
|
+
transcoder.transcode request_pb
|
868
|
+
end
|
869
|
+
|
773
870
|
##
|
774
871
|
# @private
|
775
872
|
#
|
@@ -862,6 +959,29 @@ module Google
|
|
862
959
|
transcoder.transcode request_pb
|
863
960
|
end
|
864
961
|
|
962
|
+
##
|
963
|
+
# @private
|
964
|
+
#
|
965
|
+
# GRPC transcoding helper method for the test_iam_permissions REST call
|
966
|
+
#
|
967
|
+
# @param request_pb [::Google::Cloud::Compute::V1::TestIamPermissionsBackendServiceRequest]
|
968
|
+
# A request object representing the call parameters. Required.
|
969
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
970
|
+
# Uri, Body, Query string parameters
|
971
|
+
def self.transcode_test_iam_permissions_request request_pb
|
972
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
973
|
+
.with_bindings(
|
974
|
+
uri_method: :post,
|
975
|
+
uri_template: "/compute/v1/projects/{project}/global/backendServices/{resource}/testIamPermissions",
|
976
|
+
body: "test_permissions_request_resource",
|
977
|
+
matches: [
|
978
|
+
["project", %r{^[^/]+/?$}, false],
|
979
|
+
["resource", %r{^[^/]+/?$}, false]
|
980
|
+
]
|
981
|
+
)
|
982
|
+
transcoder.transcode request_pb
|
983
|
+
end
|
984
|
+
|
865
985
|
##
|
866
986
|
# @private
|
867
987
|
#
|