google-cloud-compute-v1 3.4.0 → 3.6.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/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +181 -14
- data/lib/google/cloud/compute/v1/addresses/rest/client.rb +237 -20
- data/lib/google/cloud/compute/v1/advice/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/advice/rest/client.rb +431 -0
- data/lib/google/cloud/compute/v1/advice/rest/service_stub.rb +144 -0
- data/lib/google/cloud/compute/v1/advice/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/advice.rb +47 -0
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +334 -21
- data/lib/google/cloud/compute/v1/autoscalers/rest/service_stub.rb +64 -0
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +573 -23
- data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +122 -0
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +499 -40
- data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +62 -0
- data/lib/google/cloud/compute/v1/compute_pb.rb +357 -25
- data/lib/google/cloud/compute/v1/cross_site_networks/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/cross_site_networks/rest/client.rb +975 -0
- data/lib/google/cloud/compute/v1/cross_site_networks/rest/service_stub.rb +391 -0
- data/lib/google/cloud/compute/v1/cross_site_networks/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/cross_site_networks.rb +47 -0
- data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +181 -14
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +508 -42
- data/lib/google/cloud/compute/v1/disks/rest/service_stub.rb +64 -0
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +118 -11
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +240 -25
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +238 -13
- data/lib/google/cloud/compute/v1/firewalls/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +258 -23
- data/lib/google/cloud/compute/v1/future_reservations/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/future_reservations/rest/client.rb +1287 -0
- data/lib/google/cloud/compute/v1/future_reservations/rest/service_stub.rb +520 -0
- data/lib/google/cloud/compute/v1/future_reservations/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/future_reservations.rb +47 -0
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +126 -10
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +151 -15
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +246 -21
- data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +203 -18
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +91 -9
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +128 -10
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +333 -21
- data/lib/google/cloud/compute/v1/health_checks/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/image_family_views/rest/client.rb +2 -1
- data/lib/google/cloud/compute/v1/images/rest/client.rb +161 -18
- data/lib/google/cloud/compute/v1/instance_group_manager_resize_requests/rest/client.rb +159 -24
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +920 -95
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +380 -40
- data/lib/google/cloud/compute/v1/instance_settings_service/rest/client.rb +13 -1
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +220 -20
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +939 -104
- data/lib/google/cloud/compute/v1/instant_snapshot_groups/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest/client.rb +1145 -0
- data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest/service_stub.rb +523 -0
- data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/instant_snapshot_groups.rb +47 -0
- data/lib/google/cloud/compute/v1/instant_snapshots/rest/client.rb +235 -21
- data/lib/google/cloud/compute/v1/interconnect_attachment_groups/rest/client.rb +139 -14
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +242 -21
- data/lib/google/cloud/compute/v1/interconnect_groups/rest/client.rb +139 -14
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +87 -7
- data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest/client.rb +87 -7
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +145 -14
- data/lib/google/cloud/compute/v1/license_codes/rest/client.rb +9 -2
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +161 -16
- data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +124 -13
- data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +181 -14
- data/lib/google/cloud/compute/v1/network_attachments/rest/client.rb +232 -20
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/client.rb +138 -12
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +361 -37
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/client.rb +354 -33
- data/lib/google/cloud/compute/v1/network_profiles/rest/client.rb +85 -6
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +281 -23
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +381 -32
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +213 -19
- data/lib/google/cloud/compute/v1/node_types/rest/client.rb +181 -14
- data/lib/google/cloud/compute/v1/organization_security_policies/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/organization_security_policies/rest/client.rb +2259 -0
- data/lib/google/cloud/compute/v1/organization_security_policies/rest/service_stub.rb +1054 -0
- data/lib/google/cloud/compute/v1/organization_security_policies/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/organization_security_policies.rb +47 -0
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +226 -19
- data/lib/google/cloud/compute/v1/preview_features/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/preview_features/rest/client.rb +739 -0
- data/lib/google/cloud/compute/v1/preview_features/rest/service_stub.rb +267 -0
- data/lib/google/cloud/compute/v1/preview_features/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/preview_features.rb +47 -0
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +346 -30
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +154 -12
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +255 -22
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +238 -13
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/service_stub.rb +64 -0
- data/lib/google/cloud/compute/v1/region_backend_buckets/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_backend_buckets/rest/client.rb +1450 -0
- data/lib/google/cloud/compute/v1/region_backend_buckets/rest/service_stub.rb +649 -0
- data/lib/google/cloud/compute/v1/region_backend_buckets/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_backend_buckets.rb +47 -0
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +260 -26
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +212 -18
- data/lib/google/cloud/compute/v1/region_composite_health_checks/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_composite_health_checks/rest/client.rb +1363 -0
- data/lib/google/cloud/compute/v1/region_composite_health_checks/rest/service_stub.rb +584 -0
- data/lib/google/cloud/compute/v1/region_composite_health_checks/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_composite_health_checks.rb +47 -0
- data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +83 -5
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +387 -29
- data/lib/google/cloud/compute/v1/region_disks/rest/service_stub.rb +64 -0
- data/lib/google/cloud/compute/v1/region_health_aggregation_policies/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_health_aggregation_policies/rest/client.rb +1268 -0
- data/lib/google/cloud/compute/v1/region_health_aggregation_policies/rest/service_stub.rb +521 -0
- data/lib/google/cloud/compute/v1/region_health_aggregation_policies/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_health_aggregation_policies.rb +47 -0
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +427 -17
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/service_stub.rb +125 -0
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +238 -13
- data/lib/google/cloud/compute/v1/region_health_checks/rest/service_stub.rb +64 -0
- data/lib/google/cloud/compute/v1/region_health_sources/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_health_sources/rest/client.rb +1363 -0
- data/lib/google/cloud/compute/v1/region_health_sources/rest/service_stub.rb +584 -0
- data/lib/google/cloud/compute/v1/region_health_sources/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_health_sources.rb +47 -0
- data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest/client.rb +1002 -0
- data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest/service_stub.rb +400 -0
- data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests.rb +47 -0
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +750 -64
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +187 -14
- data/lib/google/cloud/compute/v1/region_instance_templates/rest/client.rb +115 -10
- data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +15 -2
- data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest/client.rb +1146 -0
- data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest/service_stub.rb +523 -0
- data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_instant_snapshot_groups.rb +47 -0
- data/lib/google/cloud/compute/v1/region_instant_snapshots/rest/client.rb +139 -13
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +264 -28
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/client.rb +213 -20
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +399 -11
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/service_stub.rb +125 -0
- data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +107 -10
- data/lib/google/cloud/compute/v1/region_security_policies/rest/client.rb +149 -14
- data/lib/google/cloud/compute/v1/region_snapshot_settings/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_snapshot_settings/rest/client.rb +561 -0
- data/lib/google/cloud/compute/v1/region_snapshot_settings/rest/service_stub.rb +206 -0
- data/lib/google/cloud/compute/v1/region_snapshot_settings/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_snapshot_settings.rb +47 -0
- data/lib/google/cloud/compute/v1/region_snapshots/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/region_snapshots/rest/client.rb +1388 -0
- data/lib/google/cloud/compute/v1/region_snapshots/rest/service_stub.rb +651 -0
- data/lib/google/cloud/compute/v1/region_snapshots/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/region_snapshots.rb +47 -0
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +116 -10
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/client.rb +220 -20
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +126 -10
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +158 -14
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/client.rb +113 -9
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +104 -14
- data/lib/google/cloud/compute/v1/region_zones/rest/client.rb +85 -6
- data/lib/google/cloud/compute/v1/regions/rest/client.rb +120 -7
- data/lib/google/cloud/compute/v1/reservation_blocks/rest/client.rb +396 -11
- data/lib/google/cloud/compute/v1/reservation_blocks/rest/service_stub.rb +194 -0
- data/lib/google/cloud/compute/v1/reservation_slots/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/reservation_slots/rest/client.rb +863 -0
- data/lib/google/cloud/compute/v1/reservation_slots/rest/service_stub.rb +338 -0
- data/lib/google/cloud/compute/v1/reservation_slots/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/reservation_slots.rb +47 -0
- data/lib/google/cloud/compute/v1/reservation_sub_blocks/rest/client.rb +642 -12
- data/lib/google/cloud/compute/v1/reservation_sub_blocks/rest/service_stub.rb +327 -3
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +257 -24
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +224 -19
- data/lib/google/cloud/compute/v1/rest.rb +17 -0
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +555 -50
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +202 -8
- data/lib/google/cloud/compute/v1/routes/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +316 -26
- data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +231 -21
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/client.rb +13 -1
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +245 -13
- data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +210 -17
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +315 -27
- data/lib/google/cloud/compute/v1/storage_pool_types/rest/client.rb +181 -14
- data/lib/google/cloud/compute/v1/storage_pools/rest/client.rb +321 -28
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +378 -34
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +128 -10
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +240 -20
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +306 -30
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +227 -20
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +294 -26
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +281 -19
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +329 -20
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +224 -19
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +354 -24
- data/lib/google/cloud/compute/v1/url_maps/rest/service_stub.rb +63 -0
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +224 -19
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +224 -19
- data/lib/google/cloud/compute/v1/wire_groups/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/wire_groups/rest/client.rb +980 -0
- data/lib/google/cloud/compute/v1/wire_groups/rest/service_stub.rb +396 -0
- data/lib/google/cloud/compute/v1/wire_groups/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/wire_groups.rb +47 -0
- data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +106 -10
- data/lib/google/cloud/compute/v1/zone_vm_extension_policies/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest/client.rb +975 -0
- data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest/service_stub.rb +396 -0
- data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/zone_vm_extension_policies.rb +47 -0
- data/lib/google/cloud/compute/v1/zones/rest/client.rb +83 -5
- data/lib/google/cloud/compute/v1.rb +17 -0
- data/proto_docs/google/api/client.rb +149 -29
- data/proto_docs/google/cloud/compute/v1/compute.rb +47064 -5503
- metadata +87 -2
|
@@ -76,6 +76,13 @@ module Google
|
|
|
76
76
|
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
+
default_config.rpcs.get_iam_policy.timeout = 600.0
|
|
80
|
+
default_config.rpcs.get_iam_policy.retry_policy = {
|
|
81
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
default_config.rpcs.get_version.timeout = 600.0
|
|
85
|
+
|
|
79
86
|
default_config.rpcs.list.timeout = 600.0
|
|
80
87
|
default_config.rpcs.list.retry_policy = {
|
|
81
88
|
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
|
@@ -83,6 +90,12 @@ module Google
|
|
|
83
90
|
|
|
84
91
|
default_config.rpcs.perform_maintenance.timeout = 600.0
|
|
85
92
|
|
|
93
|
+
default_config.rpcs.report_faulty.timeout = 600.0
|
|
94
|
+
|
|
95
|
+
default_config.rpcs.set_iam_policy.timeout = 600.0
|
|
96
|
+
|
|
97
|
+
default_config.rpcs.test_iam_permissions.timeout = 600.0
|
|
98
|
+
|
|
86
99
|
default_config
|
|
87
100
|
end
|
|
88
101
|
yield @configure if block_given?
|
|
@@ -214,17 +227,22 @@ module Google
|
|
|
214
227
|
# @param options [::Gapic::CallOptions, ::Hash]
|
|
215
228
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
216
229
|
#
|
|
217
|
-
# @overload get(parent_name: nil, project: nil, reservation_sub_block: nil, zone: nil)
|
|
230
|
+
# @overload get(parent_name: nil, project: nil, reservation_sub_block: nil, view: nil, zone: nil)
|
|
218
231
|
# Pass arguments to `get` via keyword arguments. Note that at
|
|
219
232
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
220
233
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
221
234
|
#
|
|
222
235
|
# @param parent_name [::String]
|
|
223
|
-
# The name of the parent reservation and parent block. In the format of
|
|
236
|
+
# The name of the parent reservation and parent block. In the format of
|
|
237
|
+
# reservations/\\{reservation_name}/reservationBlocks/\\{reservation_block_name}
|
|
224
238
|
# @param project [::String]
|
|
225
239
|
# Project ID for this request.
|
|
226
240
|
# @param reservation_sub_block [::String]
|
|
227
|
-
# The name of the reservation subBlock.
|
|
241
|
+
# The name of the reservation subBlock.
|
|
242
|
+
# Name should conform to RFC1035 or be a resource ID.
|
|
243
|
+
# @param view [::String]
|
|
244
|
+
# View of the subBlock.
|
|
245
|
+
# Check the View enum for the list of possible values.
|
|
228
246
|
# @param zone [::String]
|
|
229
247
|
# Name of the zone for this request. Zone name should conform to RFC1035.
|
|
230
248
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
@@ -285,6 +303,205 @@ module Google
|
|
|
285
303
|
raise ::Google::Cloud::Error.from_error(e)
|
|
286
304
|
end
|
|
287
305
|
|
|
306
|
+
##
|
|
307
|
+
# Gets the access control policy for a resource. May be empty if no such
|
|
308
|
+
# policy or resource exists.
|
|
309
|
+
#
|
|
310
|
+
# @overload get_iam_policy(request, options = nil)
|
|
311
|
+
# Pass arguments to `get_iam_policy` via a request object, either of type
|
|
312
|
+
# {::Google::Cloud::Compute::V1::GetIamPolicyReservationSubBlockRequest} or an equivalent Hash.
|
|
313
|
+
#
|
|
314
|
+
# @param request [::Google::Cloud::Compute::V1::GetIamPolicyReservationSubBlockRequest, ::Hash]
|
|
315
|
+
# A request object representing the call parameters. Required. To specify no
|
|
316
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
317
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
318
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
319
|
+
#
|
|
320
|
+
# @overload get_iam_policy(options_requested_policy_version: nil, parent_resource: nil, project: nil, resource: nil, zone: nil)
|
|
321
|
+
# Pass arguments to `get_iam_policy` via keyword arguments. Note that at
|
|
322
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
323
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
324
|
+
#
|
|
325
|
+
# @param options_requested_policy_version [::Integer]
|
|
326
|
+
# Requested IAM Policy version.
|
|
327
|
+
# @param parent_resource [::String]
|
|
328
|
+
# Name or id of parent resource of the resource for this request.
|
|
329
|
+
# @param project [::String]
|
|
330
|
+
# Project ID for this request.
|
|
331
|
+
# @param resource [::String]
|
|
332
|
+
# Name or id of the resource for this request.
|
|
333
|
+
# @param zone [::String]
|
|
334
|
+
# The name of the zone for this request.
|
|
335
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
336
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Policy]
|
|
337
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
338
|
+
#
|
|
339
|
+
# @return [::Google::Cloud::Compute::V1::Policy]
|
|
340
|
+
#
|
|
341
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
342
|
+
#
|
|
343
|
+
# @example Basic example
|
|
344
|
+
# require "google/cloud/compute/v1"
|
|
345
|
+
#
|
|
346
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
347
|
+
# client = Google::Cloud::Compute::V1::ReservationSubBlocks::Rest::Client.new
|
|
348
|
+
#
|
|
349
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
350
|
+
# request = Google::Cloud::Compute::V1::GetIamPolicyReservationSubBlockRequest.new
|
|
351
|
+
#
|
|
352
|
+
# # Call the get_iam_policy method.
|
|
353
|
+
# result = client.get_iam_policy request
|
|
354
|
+
#
|
|
355
|
+
# # The returned object is of type Google::Cloud::Compute::V1::Policy.
|
|
356
|
+
# p result
|
|
357
|
+
#
|
|
358
|
+
def get_iam_policy request, options = nil
|
|
359
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
360
|
+
|
|
361
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::GetIamPolicyReservationSubBlockRequest
|
|
362
|
+
|
|
363
|
+
# Converts hash and nil to an options object
|
|
364
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
365
|
+
|
|
366
|
+
# Customize the options with defaults
|
|
367
|
+
call_metadata = @config.rpcs.get_iam_policy.metadata.to_h
|
|
368
|
+
|
|
369
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
370
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
371
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
372
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
|
373
|
+
transports_version_send: [:rest]
|
|
374
|
+
|
|
375
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
376
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
377
|
+
|
|
378
|
+
options.apply_defaults timeout: @config.rpcs.get_iam_policy.timeout,
|
|
379
|
+
metadata: call_metadata,
|
|
380
|
+
retry_policy: @config.rpcs.get_iam_policy.retry_policy
|
|
381
|
+
|
|
382
|
+
options.apply_defaults timeout: @config.timeout,
|
|
383
|
+
metadata: @config.metadata,
|
|
384
|
+
retry_policy: @config.retry_policy
|
|
385
|
+
|
|
386
|
+
@reservation_sub_blocks_stub.get_iam_policy request, options do |result, operation|
|
|
387
|
+
yield result, operation if block_given?
|
|
388
|
+
end
|
|
389
|
+
rescue ::Gapic::Rest::Error => e
|
|
390
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
391
|
+
end
|
|
392
|
+
|
|
393
|
+
##
|
|
394
|
+
# Allows customers to get SBOM versions of a reservation subBlock.
|
|
395
|
+
#
|
|
396
|
+
# @overload get_version(request, options = nil)
|
|
397
|
+
# Pass arguments to `get_version` via a request object, either of type
|
|
398
|
+
# {::Google::Cloud::Compute::V1::GetVersionReservationSubBlockRequest} or an equivalent Hash.
|
|
399
|
+
#
|
|
400
|
+
# @param request [::Google::Cloud::Compute::V1::GetVersionReservationSubBlockRequest, ::Hash]
|
|
401
|
+
# A request object representing the call parameters. Required. To specify no
|
|
402
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
403
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
404
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
405
|
+
#
|
|
406
|
+
# @overload get_version(parent_name: nil, project: nil, request_id: nil, reservation_sub_block: nil, reservation_sub_blocks_get_version_request_resource: nil, zone: nil)
|
|
407
|
+
# Pass arguments to `get_version` via keyword arguments. Note that at
|
|
408
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
409
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
410
|
+
#
|
|
411
|
+
# @param parent_name [::String]
|
|
412
|
+
# The name of the parent reservation and parent block. In the format of
|
|
413
|
+
# reservations/\\{reservation_name}/reservationBlocks/\\{reservation_block_name}
|
|
414
|
+
# @param project [::String]
|
|
415
|
+
# Project ID for this request.
|
|
416
|
+
# @param request_id [::String]
|
|
417
|
+
# An optional request ID to identify requests. Specify a unique request ID so
|
|
418
|
+
# that if you must retry your request, the server will know to ignore the
|
|
419
|
+
# request if it has already been completed.
|
|
420
|
+
#
|
|
421
|
+
# For example, consider a situation where you make an initial request and
|
|
422
|
+
# the request times out. If you make the request again with the same
|
|
423
|
+
# request ID, the server can check if original operation with the same
|
|
424
|
+
# request ID was received, and if so, will ignore the second request. This
|
|
425
|
+
# prevents clients from accidentally creating duplicate commitments.
|
|
426
|
+
#
|
|
427
|
+
# The request ID must be
|
|
428
|
+
# a valid UUID with the exception that zero UUID is not supported
|
|
429
|
+
# (00000000-0000-0000-0000-000000000000).
|
|
430
|
+
# @param reservation_sub_block [::String]
|
|
431
|
+
# The name of the reservation subBlock.
|
|
432
|
+
# Name should conform to RFC1035 or be a resource ID.
|
|
433
|
+
# @param reservation_sub_blocks_get_version_request_resource [::Google::Cloud::Compute::V1::ReservationSubBlocksGetVersionRequest, ::Hash]
|
|
434
|
+
# The body resource for this request
|
|
435
|
+
# @param zone [::String]
|
|
436
|
+
# Name of the zone for this request. Zone name should conform to RFC1035.
|
|
437
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
438
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
|
439
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
440
|
+
#
|
|
441
|
+
# @return [::Gapic::GenericLRO::Operation]
|
|
442
|
+
#
|
|
443
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
444
|
+
#
|
|
445
|
+
# @example Basic example
|
|
446
|
+
# require "google/cloud/compute/v1"
|
|
447
|
+
#
|
|
448
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
449
|
+
# client = Google::Cloud::Compute::V1::ReservationSubBlocks::Rest::Client.new
|
|
450
|
+
#
|
|
451
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
452
|
+
# request = Google::Cloud::Compute::V1::GetVersionReservationSubBlockRequest.new
|
|
453
|
+
#
|
|
454
|
+
# # Call the get_version method.
|
|
455
|
+
# result = client.get_version request
|
|
456
|
+
#
|
|
457
|
+
# # The returned object is of type Google::Cloud::Compute::V1::Operation.
|
|
458
|
+
# p result
|
|
459
|
+
#
|
|
460
|
+
def get_version request, options = nil
|
|
461
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
462
|
+
|
|
463
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::GetVersionReservationSubBlockRequest
|
|
464
|
+
|
|
465
|
+
# Converts hash and nil to an options object
|
|
466
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
467
|
+
|
|
468
|
+
# Customize the options with defaults
|
|
469
|
+
call_metadata = @config.rpcs.get_version.metadata.to_h
|
|
470
|
+
|
|
471
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
472
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
473
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
474
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
|
475
|
+
transports_version_send: [:rest]
|
|
476
|
+
|
|
477
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
478
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
479
|
+
|
|
480
|
+
options.apply_defaults timeout: @config.rpcs.get_version.timeout,
|
|
481
|
+
metadata: call_metadata,
|
|
482
|
+
retry_policy: @config.rpcs.get_version.retry_policy
|
|
483
|
+
|
|
484
|
+
options.apply_defaults timeout: @config.timeout,
|
|
485
|
+
metadata: @config.metadata,
|
|
486
|
+
retry_policy: @config.retry_policy
|
|
487
|
+
|
|
488
|
+
@reservation_sub_blocks_stub.get_version request, options do |result, response|
|
|
489
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
|
490
|
+
operation: result,
|
|
491
|
+
client: zone_operations,
|
|
492
|
+
request_values: {
|
|
493
|
+
"project" => request.project,
|
|
494
|
+
"zone" => request.zone
|
|
495
|
+
},
|
|
496
|
+
options: options
|
|
497
|
+
)
|
|
498
|
+
yield result, response if block_given?
|
|
499
|
+
throw :response, result
|
|
500
|
+
end
|
|
501
|
+
rescue ::Gapic::Rest::Error => e
|
|
502
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
503
|
+
end
|
|
504
|
+
|
|
288
505
|
##
|
|
289
506
|
# Retrieves a list of reservation subBlocks under a single reservation.
|
|
290
507
|
#
|
|
@@ -304,19 +521,98 @@ module Google
|
|
|
304
521
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
305
522
|
#
|
|
306
523
|
# @param filter [::String]
|
|
307
|
-
# A filter expression that filters resources listed in the response. Most
|
|
524
|
+
# A filter expression that filters resources listed in the response. Most
|
|
525
|
+
# Compute resources support two types of filter expressions:
|
|
526
|
+
# expressions that support regular expressions and expressions that follow
|
|
527
|
+
# API improvement proposal AIP-160.
|
|
528
|
+
# These two types of filter expressions cannot be mixed in one request.
|
|
529
|
+
#
|
|
530
|
+
# If you want to use AIP-160, your expression must specify the field name, an
|
|
531
|
+
# operator, and the value that you want to use for filtering. The value
|
|
532
|
+
# must be a string, a number, or a boolean. The operator
|
|
533
|
+
# must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`.
|
|
534
|
+
#
|
|
535
|
+
# For example, if you are filtering Compute Engine instances, you can
|
|
536
|
+
# exclude instances named `example-instance` by specifying
|
|
537
|
+
# `name != example-instance`.
|
|
538
|
+
#
|
|
539
|
+
# The `:*` comparison can be used to test whether a key has been defined.
|
|
540
|
+
# For example, to find all objects with `owner` label use:
|
|
541
|
+
# ```
|
|
542
|
+
# labels.owner:*
|
|
543
|
+
# ```
|
|
544
|
+
#
|
|
545
|
+
# You can also filter nested fields. For example, you could specify
|
|
546
|
+
# `scheduling.automaticRestart = false` to include instances only
|
|
547
|
+
# if they are not scheduled for automatic restarts. You can use filtering
|
|
548
|
+
# on nested fields to filter based onresource labels.
|
|
549
|
+
#
|
|
550
|
+
# To filter on multiple expressions, provide each separate expression within
|
|
551
|
+
# parentheses. For example:
|
|
552
|
+
# ```
|
|
553
|
+
# (scheduling.automaticRestart = true)
|
|
554
|
+
# (cpuPlatform = "Intel Skylake")
|
|
555
|
+
# ```
|
|
556
|
+
# By default, each expression is an `AND` expression. However, you
|
|
557
|
+
# can include `AND` and `OR` expressions explicitly.
|
|
558
|
+
# For example:
|
|
559
|
+
# ```
|
|
560
|
+
# (cpuPlatform = "Intel Skylake") OR
|
|
561
|
+
# (cpuPlatform = "Intel Broadwell") AND
|
|
562
|
+
# (scheduling.automaticRestart = true)
|
|
563
|
+
# ```
|
|
564
|
+
#
|
|
565
|
+
# If you want to use a regular expression, use the `eq` (equal) or `ne`
|
|
566
|
+
# (not equal) operator against a single un-parenthesized expression with or
|
|
567
|
+
# without quotes or against multiple parenthesized expressions. Examples:
|
|
568
|
+
#
|
|
569
|
+
# `fieldname eq unquoted literal`
|
|
570
|
+
# `fieldname eq 'single quoted literal'`
|
|
571
|
+
# `fieldname eq "double quoted literal"`
|
|
572
|
+
# `(fieldname1 eq literal) (fieldname2 ne "literal")`
|
|
573
|
+
#
|
|
574
|
+
# The literal value is interpreted as a regular expression using GoogleRE2 library syntax.
|
|
575
|
+
# The literal value must match the entire field.
|
|
576
|
+
#
|
|
577
|
+
# For example, to filter for instances that do not end with name "instance",
|
|
578
|
+
# you would use `name ne .*instance`.
|
|
579
|
+
#
|
|
580
|
+
# You cannot combine constraints on multiple fields using regular
|
|
581
|
+
# expressions.
|
|
308
582
|
# @param max_results [::Integer]
|
|
309
|
-
# The maximum number of results per page that should be returned.
|
|
583
|
+
# The maximum number of results per page that should be returned.
|
|
584
|
+
# If the number of available results is larger than `maxResults`,
|
|
585
|
+
# Compute Engine returns a `nextPageToken` that can be used to get
|
|
586
|
+
# the next page of results in subsequent list requests. Acceptable values are
|
|
587
|
+
# `0` to `500`, inclusive. (Default: `500`)
|
|
310
588
|
# @param order_by [::String]
|
|
311
|
-
# Sorts list results by a certain order. By default, results
|
|
589
|
+
# Sorts list results by a certain order. By default, results
|
|
590
|
+
# are returned in alphanumerical order based on the resource name.
|
|
591
|
+
#
|
|
592
|
+
# You can also sort results in descending order based on the creation
|
|
593
|
+
# timestamp using `orderBy="creationTimestamp desc"`. This sorts
|
|
594
|
+
# results based on the `creationTimestamp` field in
|
|
595
|
+
# reverse chronological order (newest result first). Use this to sort
|
|
596
|
+
# resources like operations so that the newest operation is returned first.
|
|
597
|
+
#
|
|
598
|
+
# Currently, only sorting by `name` or
|
|
599
|
+
# `creationTimestamp desc` is supported.
|
|
312
600
|
# @param page_token [::String]
|
|
313
|
-
# Specifies a page token to use. Set `pageToken` to the
|
|
601
|
+
# Specifies a page token to use. Set `pageToken` to the
|
|
602
|
+
# `nextPageToken` returned by a previous list request to get
|
|
603
|
+
# the next page of results.
|
|
314
604
|
# @param parent_name [::String]
|
|
315
|
-
# The name of the parent reservation and parent block. In the format of
|
|
605
|
+
# The name of the parent reservation and parent block. In the format of
|
|
606
|
+
# reservations/\\{reservation_name}/reservationBlocks/\\{reservation_block_name}
|
|
316
607
|
# @param project [::String]
|
|
317
608
|
# Project ID for this request.
|
|
318
609
|
# @param return_partial_success [::Boolean]
|
|
319
|
-
# Opt-in for partial success behavior which provides partial results in case
|
|
610
|
+
# Opt-in for partial success behavior which provides partial results in case
|
|
611
|
+
# of failure. The default value is false.
|
|
612
|
+
#
|
|
613
|
+
# For example, when partial success behavior is enabled, aggregatedList for a
|
|
614
|
+
# single zone scope either returns all resources in the zone or no resources,
|
|
615
|
+
# with an error code.
|
|
320
616
|
# @param zone [::String]
|
|
321
617
|
# Name of the zone for this request. Zone name should conform to RFC1035.
|
|
322
618
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
@@ -398,13 +694,27 @@ module Google
|
|
|
398
694
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
399
695
|
#
|
|
400
696
|
# @param parent_name [::String]
|
|
401
|
-
# The name of the parent reservation and parent block. In the format of
|
|
697
|
+
# The name of the parent reservation and parent block. In the format of
|
|
698
|
+
# reservations/\\{reservation_name}/reservationBlocks/\\{reservation_block_name}
|
|
402
699
|
# @param project [::String]
|
|
403
700
|
# Project ID for this request.
|
|
404
701
|
# @param request_id [::String]
|
|
405
|
-
# An optional request ID to identify requests. Specify a unique request ID so
|
|
702
|
+
# An optional request ID to identify requests. Specify a unique request ID so
|
|
703
|
+
# that if you must retry your request, the server will know to ignore the
|
|
704
|
+
# request if it has already been completed.
|
|
705
|
+
#
|
|
706
|
+
# For example, consider a situation where you make an initial request and
|
|
707
|
+
# the request times out. If you make the request again with the same
|
|
708
|
+
# request ID, the server can check if original operation with the same
|
|
709
|
+
# request ID was received, and if so, will ignore the second request. This
|
|
710
|
+
# prevents clients from accidentally creating duplicate commitments.
|
|
711
|
+
#
|
|
712
|
+
# The request ID must be
|
|
713
|
+
# a valid UUID with the exception that zero UUID is not supported
|
|
714
|
+
# (00000000-0000-0000-0000-000000000000).
|
|
406
715
|
# @param reservation_sub_block [::String]
|
|
407
|
-
# The name of the reservation subBlock.
|
|
716
|
+
# The name of the reservation subBlock.
|
|
717
|
+
# Name should conform to RFC1035 or be a resource ID.
|
|
408
718
|
# @param zone [::String]
|
|
409
719
|
# Name of the zone for this request. Zone name should conform to RFC1035.
|
|
410
720
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
@@ -475,6 +785,291 @@ module Google
|
|
|
475
785
|
raise ::Google::Cloud::Error.from_error(e)
|
|
476
786
|
end
|
|
477
787
|
|
|
788
|
+
##
|
|
789
|
+
# Allows customers to report a faulty subBlock.
|
|
790
|
+
#
|
|
791
|
+
# @overload report_faulty(request, options = nil)
|
|
792
|
+
# Pass arguments to `report_faulty` via a request object, either of type
|
|
793
|
+
# {::Google::Cloud::Compute::V1::ReportFaultyReservationSubBlockRequest} or an equivalent Hash.
|
|
794
|
+
#
|
|
795
|
+
# @param request [::Google::Cloud::Compute::V1::ReportFaultyReservationSubBlockRequest, ::Hash]
|
|
796
|
+
# A request object representing the call parameters. Required. To specify no
|
|
797
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
798
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
799
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
800
|
+
#
|
|
801
|
+
# @overload report_faulty(parent_name: nil, project: nil, request_id: nil, reservation_sub_block: nil, reservation_sub_blocks_report_faulty_request_resource: nil, zone: nil)
|
|
802
|
+
# Pass arguments to `report_faulty` via keyword arguments. Note that at
|
|
803
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
804
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
805
|
+
#
|
|
806
|
+
# @param parent_name [::String]
|
|
807
|
+
# The name of the parent reservation and parent block. In the format of
|
|
808
|
+
# reservations/\\{reservation_name}/reservationBlocks/\\{reservation_block_name}
|
|
809
|
+
# @param project [::String]
|
|
810
|
+
# Project ID for this request.
|
|
811
|
+
# @param request_id [::String]
|
|
812
|
+
# An optional request ID to identify requests. Specify a unique request ID so
|
|
813
|
+
# that if you must retry your request, the server will know to ignore the
|
|
814
|
+
# request if it has already been completed.
|
|
815
|
+
#
|
|
816
|
+
# For example, consider a situation where you make an initial request and
|
|
817
|
+
# the request times out. If you make the request again with the same
|
|
818
|
+
# request ID, the server can check if original operation with the same
|
|
819
|
+
# request ID was received, and if so, will ignore the second request. This
|
|
820
|
+
# prevents clients from accidentally creating duplicate commitments.
|
|
821
|
+
#
|
|
822
|
+
# The request ID must be
|
|
823
|
+
# a valid UUID with the exception that zero UUID is not supported
|
|
824
|
+
# (00000000-0000-0000-0000-000000000000).
|
|
825
|
+
# @param reservation_sub_block [::String]
|
|
826
|
+
# The name of the reservation subBlock.
|
|
827
|
+
# Name should conform to RFC1035 or be a resource ID.
|
|
828
|
+
# @param reservation_sub_blocks_report_faulty_request_resource [::Google::Cloud::Compute::V1::ReservationSubBlocksReportFaultyRequest, ::Hash]
|
|
829
|
+
# The body resource for this request
|
|
830
|
+
# @param zone [::String]
|
|
831
|
+
# Name of the zone for this request. Zone name should conform to RFC1035.
|
|
832
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
833
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
|
834
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
835
|
+
#
|
|
836
|
+
# @return [::Gapic::GenericLRO::Operation]
|
|
837
|
+
#
|
|
838
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
839
|
+
#
|
|
840
|
+
# @example Basic example
|
|
841
|
+
# require "google/cloud/compute/v1"
|
|
842
|
+
#
|
|
843
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
844
|
+
# client = Google::Cloud::Compute::V1::ReservationSubBlocks::Rest::Client.new
|
|
845
|
+
#
|
|
846
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
847
|
+
# request = Google::Cloud::Compute::V1::ReportFaultyReservationSubBlockRequest.new
|
|
848
|
+
#
|
|
849
|
+
# # Call the report_faulty method.
|
|
850
|
+
# result = client.report_faulty request
|
|
851
|
+
#
|
|
852
|
+
# # The returned object is of type Google::Cloud::Compute::V1::Operation.
|
|
853
|
+
# p result
|
|
854
|
+
#
|
|
855
|
+
def report_faulty request, options = nil
|
|
856
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
857
|
+
|
|
858
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::ReportFaultyReservationSubBlockRequest
|
|
859
|
+
|
|
860
|
+
# Converts hash and nil to an options object
|
|
861
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
862
|
+
|
|
863
|
+
# Customize the options with defaults
|
|
864
|
+
call_metadata = @config.rpcs.report_faulty.metadata.to_h
|
|
865
|
+
|
|
866
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
867
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
868
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
869
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
|
870
|
+
transports_version_send: [:rest]
|
|
871
|
+
|
|
872
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
873
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
874
|
+
|
|
875
|
+
options.apply_defaults timeout: @config.rpcs.report_faulty.timeout,
|
|
876
|
+
metadata: call_metadata,
|
|
877
|
+
retry_policy: @config.rpcs.report_faulty.retry_policy
|
|
878
|
+
|
|
879
|
+
options.apply_defaults timeout: @config.timeout,
|
|
880
|
+
metadata: @config.metadata,
|
|
881
|
+
retry_policy: @config.retry_policy
|
|
882
|
+
|
|
883
|
+
@reservation_sub_blocks_stub.report_faulty request, options do |result, response|
|
|
884
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
|
885
|
+
operation: result,
|
|
886
|
+
client: zone_operations,
|
|
887
|
+
request_values: {
|
|
888
|
+
"project" => request.project,
|
|
889
|
+
"zone" => request.zone
|
|
890
|
+
},
|
|
891
|
+
options: options
|
|
892
|
+
)
|
|
893
|
+
yield result, response if block_given?
|
|
894
|
+
throw :response, result
|
|
895
|
+
end
|
|
896
|
+
rescue ::Gapic::Rest::Error => e
|
|
897
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
898
|
+
end
|
|
899
|
+
|
|
900
|
+
##
|
|
901
|
+
# Sets the access control policy on the specified resource.
|
|
902
|
+
# Replaces any existing policy.
|
|
903
|
+
#
|
|
904
|
+
# @overload set_iam_policy(request, options = nil)
|
|
905
|
+
# Pass arguments to `set_iam_policy` via a request object, either of type
|
|
906
|
+
# {::Google::Cloud::Compute::V1::SetIamPolicyReservationSubBlockRequest} or an equivalent Hash.
|
|
907
|
+
#
|
|
908
|
+
# @param request [::Google::Cloud::Compute::V1::SetIamPolicyReservationSubBlockRequest, ::Hash]
|
|
909
|
+
# A request object representing the call parameters. Required. To specify no
|
|
910
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
911
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
912
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
913
|
+
#
|
|
914
|
+
# @overload set_iam_policy(parent_resource: nil, project: nil, resource: nil, zone: nil, zone_set_nested_policy_request_resource: nil)
|
|
915
|
+
# Pass arguments to `set_iam_policy` via keyword arguments. Note that at
|
|
916
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
917
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
918
|
+
#
|
|
919
|
+
# @param parent_resource [::String]
|
|
920
|
+
# Name or id of parent resource of the resource for this request.
|
|
921
|
+
# @param project [::String]
|
|
922
|
+
# Project ID for this request.
|
|
923
|
+
# @param resource [::String]
|
|
924
|
+
# Name or id of the resource for this request.
|
|
925
|
+
# @param zone [::String]
|
|
926
|
+
# The name of the zone for this request.
|
|
927
|
+
# @param zone_set_nested_policy_request_resource [::Google::Cloud::Compute::V1::ZoneSetNestedPolicyRequest, ::Hash]
|
|
928
|
+
# The body resource for this request
|
|
929
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
930
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Policy]
|
|
931
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
932
|
+
#
|
|
933
|
+
# @return [::Google::Cloud::Compute::V1::Policy]
|
|
934
|
+
#
|
|
935
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
936
|
+
#
|
|
937
|
+
# @example Basic example
|
|
938
|
+
# require "google/cloud/compute/v1"
|
|
939
|
+
#
|
|
940
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
941
|
+
# client = Google::Cloud::Compute::V1::ReservationSubBlocks::Rest::Client.new
|
|
942
|
+
#
|
|
943
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
944
|
+
# request = Google::Cloud::Compute::V1::SetIamPolicyReservationSubBlockRequest.new
|
|
945
|
+
#
|
|
946
|
+
# # Call the set_iam_policy method.
|
|
947
|
+
# result = client.set_iam_policy request
|
|
948
|
+
#
|
|
949
|
+
# # The returned object is of type Google::Cloud::Compute::V1::Policy.
|
|
950
|
+
# p result
|
|
951
|
+
#
|
|
952
|
+
def set_iam_policy request, options = nil
|
|
953
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
954
|
+
|
|
955
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::SetIamPolicyReservationSubBlockRequest
|
|
956
|
+
|
|
957
|
+
# Converts hash and nil to an options object
|
|
958
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
959
|
+
|
|
960
|
+
# Customize the options with defaults
|
|
961
|
+
call_metadata = @config.rpcs.set_iam_policy.metadata.to_h
|
|
962
|
+
|
|
963
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
964
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
965
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
966
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
|
967
|
+
transports_version_send: [:rest]
|
|
968
|
+
|
|
969
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
970
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
971
|
+
|
|
972
|
+
options.apply_defaults timeout: @config.rpcs.set_iam_policy.timeout,
|
|
973
|
+
metadata: call_metadata,
|
|
974
|
+
retry_policy: @config.rpcs.set_iam_policy.retry_policy
|
|
975
|
+
|
|
976
|
+
options.apply_defaults timeout: @config.timeout,
|
|
977
|
+
metadata: @config.metadata,
|
|
978
|
+
retry_policy: @config.retry_policy
|
|
979
|
+
|
|
980
|
+
@reservation_sub_blocks_stub.set_iam_policy request, options do |result, operation|
|
|
981
|
+
yield result, operation if block_given?
|
|
982
|
+
end
|
|
983
|
+
rescue ::Gapic::Rest::Error => e
|
|
984
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
985
|
+
end
|
|
986
|
+
|
|
987
|
+
##
|
|
988
|
+
# Returns permissions that a caller has on the specified resource.
|
|
989
|
+
#
|
|
990
|
+
# @overload test_iam_permissions(request, options = nil)
|
|
991
|
+
# Pass arguments to `test_iam_permissions` via a request object, either of type
|
|
992
|
+
# {::Google::Cloud::Compute::V1::TestIamPermissionsReservationSubBlockRequest} or an equivalent Hash.
|
|
993
|
+
#
|
|
994
|
+
# @param request [::Google::Cloud::Compute::V1::TestIamPermissionsReservationSubBlockRequest, ::Hash]
|
|
995
|
+
# A request object representing the call parameters. Required. To specify no
|
|
996
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
997
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
998
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
999
|
+
#
|
|
1000
|
+
# @overload test_iam_permissions(parent_resource: nil, project: nil, resource: nil, test_permissions_request_resource: nil, zone: nil)
|
|
1001
|
+
# Pass arguments to `test_iam_permissions` via keyword arguments. Note that at
|
|
1002
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
1003
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
1004
|
+
#
|
|
1005
|
+
# @param parent_resource [::String]
|
|
1006
|
+
# Name or id of parent resource of the resource for this request.
|
|
1007
|
+
# @param project [::String]
|
|
1008
|
+
# Project ID for this request.
|
|
1009
|
+
# @param resource [::String]
|
|
1010
|
+
# Name or id of the resource for this request.
|
|
1011
|
+
# @param test_permissions_request_resource [::Google::Cloud::Compute::V1::TestPermissionsRequest, ::Hash]
|
|
1012
|
+
# The body resource for this request
|
|
1013
|
+
# @param zone [::String]
|
|
1014
|
+
# The name of the zone for this request.
|
|
1015
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1016
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
|
1017
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1018
|
+
#
|
|
1019
|
+
# @return [::Google::Cloud::Compute::V1::TestPermissionsResponse]
|
|
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::ReservationSubBlocks::Rest::Client.new
|
|
1028
|
+
#
|
|
1029
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
1030
|
+
# request = Google::Cloud::Compute::V1::TestIamPermissionsReservationSubBlockRequest.new
|
|
1031
|
+
#
|
|
1032
|
+
# # Call the test_iam_permissions method.
|
|
1033
|
+
# result = client.test_iam_permissions request
|
|
1034
|
+
#
|
|
1035
|
+
# # The returned object is of type Google::Cloud::Compute::V1::TestPermissionsResponse.
|
|
1036
|
+
# p result
|
|
1037
|
+
#
|
|
1038
|
+
def test_iam_permissions 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::TestIamPermissionsReservationSubBlockRequest
|
|
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.test_iam_permissions.metadata.to_h
|
|
1048
|
+
|
|
1049
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version 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-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
1056
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
1057
|
+
|
|
1058
|
+
options.apply_defaults timeout: @config.rpcs.test_iam_permissions.timeout,
|
|
1059
|
+
metadata: call_metadata,
|
|
1060
|
+
retry_policy: @config.rpcs.test_iam_permissions.retry_policy
|
|
1061
|
+
|
|
1062
|
+
options.apply_defaults timeout: @config.timeout,
|
|
1063
|
+
metadata: @config.metadata,
|
|
1064
|
+
retry_policy: @config.retry_policy
|
|
1065
|
+
|
|
1066
|
+
@reservation_sub_blocks_stub.test_iam_permissions request, options do |result, operation|
|
|
1067
|
+
yield result, operation if block_given?
|
|
1068
|
+
end
|
|
1069
|
+
rescue ::Gapic::Rest::Error => e
|
|
1070
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
1071
|
+
end
|
|
1072
|
+
|
|
478
1073
|
##
|
|
479
1074
|
# Configuration class for the ReservationSubBlocks REST API.
|
|
480
1075
|
#
|
|
@@ -627,6 +1222,16 @@ module Google
|
|
|
627
1222
|
#
|
|
628
1223
|
attr_reader :get
|
|
629
1224
|
##
|
|
1225
|
+
# RPC-specific configuration for `get_iam_policy`
|
|
1226
|
+
# @return [::Gapic::Config::Method]
|
|
1227
|
+
#
|
|
1228
|
+
attr_reader :get_iam_policy
|
|
1229
|
+
##
|
|
1230
|
+
# RPC-specific configuration for `get_version`
|
|
1231
|
+
# @return [::Gapic::Config::Method]
|
|
1232
|
+
#
|
|
1233
|
+
attr_reader :get_version
|
|
1234
|
+
##
|
|
630
1235
|
# RPC-specific configuration for `list`
|
|
631
1236
|
# @return [::Gapic::Config::Method]
|
|
632
1237
|
#
|
|
@@ -636,15 +1241,40 @@ module Google
|
|
|
636
1241
|
# @return [::Gapic::Config::Method]
|
|
637
1242
|
#
|
|
638
1243
|
attr_reader :perform_maintenance
|
|
1244
|
+
##
|
|
1245
|
+
# RPC-specific configuration for `report_faulty`
|
|
1246
|
+
# @return [::Gapic::Config::Method]
|
|
1247
|
+
#
|
|
1248
|
+
attr_reader :report_faulty
|
|
1249
|
+
##
|
|
1250
|
+
# RPC-specific configuration for `set_iam_policy`
|
|
1251
|
+
# @return [::Gapic::Config::Method]
|
|
1252
|
+
#
|
|
1253
|
+
attr_reader :set_iam_policy
|
|
1254
|
+
##
|
|
1255
|
+
# RPC-specific configuration for `test_iam_permissions`
|
|
1256
|
+
# @return [::Gapic::Config::Method]
|
|
1257
|
+
#
|
|
1258
|
+
attr_reader :test_iam_permissions
|
|
639
1259
|
|
|
640
1260
|
# @private
|
|
641
1261
|
def initialize parent_rpcs = nil
|
|
642
1262
|
get_config = parent_rpcs.get if parent_rpcs.respond_to? :get
|
|
643
1263
|
@get = ::Gapic::Config::Method.new get_config
|
|
1264
|
+
get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
|
|
1265
|
+
@get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
|
|
1266
|
+
get_version_config = parent_rpcs.get_version if parent_rpcs.respond_to? :get_version
|
|
1267
|
+
@get_version = ::Gapic::Config::Method.new get_version_config
|
|
644
1268
|
list_config = parent_rpcs.list if parent_rpcs.respond_to? :list
|
|
645
1269
|
@list = ::Gapic::Config::Method.new list_config
|
|
646
1270
|
perform_maintenance_config = parent_rpcs.perform_maintenance if parent_rpcs.respond_to? :perform_maintenance
|
|
647
1271
|
@perform_maintenance = ::Gapic::Config::Method.new perform_maintenance_config
|
|
1272
|
+
report_faulty_config = parent_rpcs.report_faulty if parent_rpcs.respond_to? :report_faulty
|
|
1273
|
+
@report_faulty = ::Gapic::Config::Method.new report_faulty_config
|
|
1274
|
+
set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
|
|
1275
|
+
@set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
|
|
1276
|
+
test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
|
|
1277
|
+
@test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
|
|
648
1278
|
|
|
649
1279
|
yield self if block_given?
|
|
650
1280
|
end
|