google-cloud-compute-v1 1.8.0 → 1.10.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 +76 -50
- data/lib/google/cloud/compute/v1/accelerator_types/rest/service_stub.rb +9 -10
- data/lib/google/cloud/compute/v1/accelerator_types/rest.rb +20 -0
- data/lib/google/cloud/compute/v1/accelerator_types.rb +2 -2
- data/lib/google/cloud/compute/v1/addresses/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/addresses/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/addresses/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/addresses.rb +2 -2
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/autoscalers/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/autoscalers/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/autoscalers.rb +2 -2
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/backend_buckets/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/backend_buckets.rb +2 -2
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +176 -171
- data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +31 -32
- data/lib/google/cloud/compute/v1/backend_services/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/backend_services.rb +2 -2
- data/lib/google/cloud/compute/v1/compute_pb.rb +206 -0
- data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +76 -50
- data/lib/google/cloud/compute/v1/disk_types/rest/service_stub.rb +9 -10
- data/lib/google/cloud/compute/v1/disk_types/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/disk_types.rb +2 -2
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +167 -160
- data/lib/google/cloud/compute/v1/disks/rest/service_stub.rb +29 -30
- data/lib/google/cloud/compute/v1/disks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/disks.rb +2 -2
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/external_vpn_gateways.rb +2 -2
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +212 -215
- data/lib/google/cloud/compute/v1/firewall_policies/rest/service_stub.rb +39 -40
- data/lib/google/cloud/compute/v1/firewall_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/firewall_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/firewalls/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/firewalls/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/firewalls.rb +2 -2
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +122 -105
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/service_stub.rb +19 -20
- data/lib/google/cloud/compute/v1/forwarding_rules/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/forwarding_rules.rb +2 -2
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/global_addresses/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/global_addresses/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_addresses.rb +2 -2
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_forwarding_rules.rb +2 -2
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +94 -72
- data/lib/google/cloud/compute/v1/global_operations/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/global_operations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_operations.rb +2 -2
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +76 -50
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/service_stub.rb +9 -10
- data/lib/google/cloud/compute/v1/global_organization_operations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_organization_operations.rb +2 -2
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes.rb +2 -2
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/health_checks/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/health_checks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/health_checks.rb +2 -2
- data/lib/google/cloud/compute/v1/image_family_views/rest/client.rb +58 -28
- data/lib/google/cloud/compute/v1/image_family_views/rest/service_stub.rb +5 -6
- data/lib/google/cloud/compute/v1/image_family_views/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/image_family_views.rb +2 -2
- data/lib/google/cloud/compute/v1/images/rest/client.rb +149 -138
- data/lib/google/cloud/compute/v1/images/rest/service_stub.rb +25 -26
- data/lib/google/cloud/compute/v1/images/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/images.rb +2 -2
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +230 -237
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/service_stub.rb +43 -44
- data/lib/google/cloud/compute/v1/instance_group_managers/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/instance_group_managers.rb +2 -2
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/instance_groups/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/instance_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/instance_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/instance_templates/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/instance_templates/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/instance_templates.rb +2 -2
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +461 -514
- data/lib/google/cloud/compute/v1/instances/rest/service_stub.rb +93 -94
- data/lib/google/cloud/compute/v1/instances/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/instances.rb +2 -2
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/interconnect_attachments.rb +2 -2
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +67 -39
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/service_stub.rb +7 -8
- data/lib/google/cloud/compute/v1/interconnect_locations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/interconnect_locations.rb +2 -2
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +119 -100
- data/lib/google/cloud/compute/v1/interconnects/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/interconnects/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/interconnects.rb +2 -2
- data/lib/google/cloud/compute/v1/license_codes/rest/client.rb +67 -39
- data/lib/google/cloud/compute/v1/license_codes/rest/service_stub.rb +7 -8
- data/lib/google/cloud/compute/v1/license_codes/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/license_codes.rb +2 -2
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/licenses/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/licenses/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/licenses.rb +2 -2
- data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/machine_images/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/machine_images/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/machine_images.rb +2 -2
- data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +76 -50
- data/lib/google/cloud/compute/v1/machine_types/rest/service_stub.rb +9 -10
- data/lib/google/cloud/compute/v1/machine_types/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/machine_types.rb +2 -2
- data/lib/google/cloud/compute/v1/network_attachments/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/network_attachments/rest/client.rb +945 -0
- data/lib/google/cloud/compute/v1/network_attachments/rest/service_stub.rb +527 -0
- data/lib/google/cloud/compute/v1/network_attachments/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/network_attachments.rb +47 -0
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/network_edge_security_services.rb +2 -2
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/network_endpoint_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/client.rb +194 -193
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/service_stub.rb +35 -36
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/network_firewall_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +149 -138
- data/lib/google/cloud/compute/v1/networks/rest/service_stub.rb +25 -26
- data/lib/google/cloud/compute/v1/networks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/networks.rb +2 -2
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +167 -160
- data/lib/google/cloud/compute/v1/node_groups/rest/service_stub.rb +29 -30
- data/lib/google/cloud/compute/v1/node_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/node_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +122 -105
- data/lib/google/cloud/compute/v1/node_templates/rest/service_stub.rb +19 -20
- data/lib/google/cloud/compute/v1/node_templates/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/node_templates.rb +2 -2
- data/lib/google/cloud/compute/v1/node_types/rest/client.rb +76 -50
- data/lib/google/cloud/compute/v1/node_types/rest/service_stub.rb +9 -10
- data/lib/google/cloud/compute/v1/node_types/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/node_types.rb +2 -2
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/packet_mirrorings.rb +2 -2
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +167 -160
- data/lib/google/cloud/compute/v1/projects/rest/service_stub.rb +29 -30
- data/lib/google/cloud/compute/v1/projects/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/projects.rb +2 -2
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/public_advertised_prefixes.rb +2 -2
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/public_delegated_prefixes.rb +2 -2
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/region_autoscalers/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_autoscalers.rb +2 -2
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/region_backend_services/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/region_backend_services/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_backend_services.rb +2 -2
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/region_commitments/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/region_commitments/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_commitments.rb +2 -2
- data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +67 -39
- data/lib/google/cloud/compute/v1/region_disk_types/rest/service_stub.rb +7 -8
- data/lib/google/cloud/compute/v1/region_disk_types/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_disk_types.rb +2 -2
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +158 -149
- data/lib/google/cloud/compute/v1/region_disks/rest/service_stub.rb +27 -28
- data/lib/google/cloud/compute/v1/region_disks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_disks.rb +2 -2
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/region_health_check_services/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_health_check_services.rb +2 -2
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/region_health_checks/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/region_health_checks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_health_checks.rb +2 -2
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +221 -226
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/service_stub.rb +41 -42
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_instance_group_managers.rb +2 -2
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_instance_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_instance_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +59 -28
- data/lib/google/cloud/compute/v1/region_instances/rest/service_stub.rb +5 -6
- data/lib/google/cloud/compute/v1/region_instances/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_instances.rb +2 -2
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups.rb +2 -2
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/client.rb +203 -204
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/service_stub.rb +37 -38
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_network_firewall_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_notification_endpoints.rb +2 -2
- data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +85 -61
- data/lib/google/cloud/compute/v1/region_operations/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_operations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_operations.rb +2 -2
- data/lib/google/cloud/compute/v1/region_security_policies/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/region_security_policies/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/region_security_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_security_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_ssl_certificates.rb +2 -2
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_ssl_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_target_http_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_target_https_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/region_url_maps/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/region_url_maps/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/region_url_maps.rb +2 -2
- data/lib/google/cloud/compute/v1/regions/rest/client.rb +67 -39
- data/lib/google/cloud/compute/v1/regions/rest/service_stub.rb +7 -8
- data/lib/google/cloud/compute/v1/regions/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/regions.rb +2 -2
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +140 -127
- data/lib/google/cloud/compute/v1/reservations/rest/service_stub.rb +23 -24
- data/lib/google/cloud/compute/v1/reservations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/reservations.rb +2 -2
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +122 -105
- data/lib/google/cloud/compute/v1/resource_policies/rest/service_stub.rb +19 -20
- data/lib/google/cloud/compute/v1/resource_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/resource_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/rest.rb +124 -0
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +140 -127
- data/lib/google/cloud/compute/v1/routers/rest/service_stub.rb +23 -24
- data/lib/google/cloud/compute/v1/routers/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/routers.rb +2 -2
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +86 -61
- data/lib/google/cloud/compute/v1/routes/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/routes/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/routes.rb +2 -2
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +158 -149
- data/lib/google/cloud/compute/v1/security_policies/rest/service_stub.rb +27 -28
- data/lib/google/cloud/compute/v1/security_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/security_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/service_attachments/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/service_attachments/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/service_attachments.rb +2 -2
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +122 -105
- data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +19 -20
- data/lib/google/cloud/compute/v1/snapshots/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/snapshots.rb +2 -2
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/ssl_certificates/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/ssl_certificates.rb +2 -2
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/ssl_policies/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/ssl_policies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/ssl_policies.rb +2 -2
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +158 -149
- data/lib/google/cloud/compute/v1/subnetworks/rest/service_stub.rb +27 -28
- data/lib/google/cloud/compute/v1/subnetworks/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/subnetworks.rb +2 -2
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_grpc_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +113 -94
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/service_stub.rb +17 -18
- data/lib/google/cloud/compute/v1/target_http_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_http_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +149 -138
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/service_stub.rb +25 -26
- data/lib/google/cloud/compute/v1/target_https_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_https_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +95 -72
- data/lib/google/cloud/compute/v1/target_instances/rest/service_stub.rb +13 -14
- data/lib/google/cloud/compute/v1/target_instances/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_instances.rb +2 -2
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +149 -138
- data/lib/google/cloud/compute/v1/target_pools/rest/service_stub.rb +25 -26
- data/lib/google/cloud/compute/v1/target_pools/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_pools.rb +2 -2
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_ssl_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +191 -83
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/service_stub.rb +72 -15
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_tcp_proxies.rb +2 -2
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/target_vpn_gateways.rb +2 -2
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +131 -116
- data/lib/google/cloud/compute/v1/url_maps/rest/service_stub.rb +21 -22
- data/lib/google/cloud/compute/v1/url_maps/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/url_maps.rb +2 -2
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +122 -105
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/service_stub.rb +19 -20
- data/lib/google/cloud/compute/v1/vpn_gateways/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/vpn_gateways.rb +2 -2
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +104 -83
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/service_stub.rb +15 -16
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/vpn_tunnels.rb +2 -2
- data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +85 -61
- data/lib/google/cloud/compute/v1/zone_operations/rest/service_stub.rb +11 -12
- data/lib/google/cloud/compute/v1/zone_operations/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/zone_operations.rb +2 -2
- data/lib/google/cloud/compute/v1/zones/rest/client.rb +67 -39
- data/lib/google/cloud/compute/v1/zones/rest/service_stub.rb +7 -8
- data/lib/google/cloud/compute/v1/zones/rest.rb +18 -0
- data/lib/google/cloud/compute/v1/zones.rb +2 -2
- data/lib/google/cloud/compute/v1.rb +3 -2
- data/proto_docs/google/api/client.rb +318 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/cloud/compute/v1/compute.rb +564 -32
- data/proto_docs/google/protobuf/duration.rb +98 -0
- metadata +14 -5
@@ -147,13 +147,22 @@ module Google
|
|
147
147
|
|
148
148
|
# Create credentials
|
149
149
|
credentials = @config.credentials
|
150
|
-
|
150
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
151
|
+
# but only if the default endpoint does not have a region prefix.
|
152
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
153
|
+
!@config.endpoint.split(".").first.include?("-")
|
154
|
+
credentials ||= Credentials.default scope: @config.scope,
|
155
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
151
156
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
152
157
|
credentials = Credentials.new credentials, scope: @config.scope
|
153
158
|
end
|
154
159
|
|
160
|
+
@quota_project_id = @config.quota_project
|
161
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
162
|
+
|
155
163
|
@region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
|
156
164
|
config.credentials = credentials
|
165
|
+
config.quota_project = @quota_project_id
|
157
166
|
config.endpoint = @config.endpoint
|
158
167
|
end
|
159
168
|
|
@@ -181,8 +190,6 @@ module Google
|
|
181
190
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
182
191
|
# @param options [::Gapic::CallOptions, ::Hash]
|
183
192
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
184
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
185
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
186
193
|
#
|
187
194
|
# @overload add_health_check(project: nil, region: nil, request_id: nil, target_pool: nil, target_pools_add_health_check_request_resource: nil)
|
188
195
|
# Pass arguments to `add_health_check` via keyword arguments. Note that at
|
@@ -217,17 +224,21 @@ module Google
|
|
217
224
|
# Customize the options with defaults
|
218
225
|
call_metadata = @config.rpcs.add_health_check.metadata.to_h
|
219
226
|
|
220
|
-
# Set x-goog-api-client
|
227
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
221
228
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
222
229
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
223
230
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
224
231
|
transports_version_send: [:rest]
|
225
232
|
|
233
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
234
|
+
|
226
235
|
options.apply_defaults timeout: @config.rpcs.add_health_check.timeout,
|
227
|
-
metadata: call_metadata
|
236
|
+
metadata: call_metadata,
|
237
|
+
retry_policy: @config.rpcs.add_health_check.retry_policy
|
228
238
|
|
229
239
|
options.apply_defaults timeout: @config.timeout,
|
230
|
-
metadata: @config.metadata
|
240
|
+
metadata: @config.metadata,
|
241
|
+
retry_policy: @config.retry_policy
|
231
242
|
|
232
243
|
@target_pools_stub.add_health_check request, options do |result, response|
|
233
244
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -242,12 +253,8 @@ module Google
|
|
242
253
|
yield result, response if block_given?
|
243
254
|
return result
|
244
255
|
end
|
245
|
-
rescue ::
|
246
|
-
|
247
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
248
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
249
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
250
|
-
end
|
256
|
+
rescue ::Gapic::Rest::Error => e
|
257
|
+
raise ::Google::Cloud::Error.from_error(e)
|
251
258
|
end
|
252
259
|
|
253
260
|
##
|
@@ -262,8 +269,6 @@ module Google
|
|
262
269
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
263
270
|
# @param options [::Gapic::CallOptions, ::Hash]
|
264
271
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
265
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
266
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
267
272
|
#
|
268
273
|
# @overload add_instance(project: nil, region: nil, request_id: nil, target_pool: nil, target_pools_add_instance_request_resource: nil)
|
269
274
|
# Pass arguments to `add_instance` via keyword arguments. Note that at
|
@@ -298,17 +303,21 @@ module Google
|
|
298
303
|
# Customize the options with defaults
|
299
304
|
call_metadata = @config.rpcs.add_instance.metadata.to_h
|
300
305
|
|
301
|
-
# Set x-goog-api-client
|
306
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
302
307
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
303
308
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
304
309
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
305
310
|
transports_version_send: [:rest]
|
306
311
|
|
312
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
313
|
+
|
307
314
|
options.apply_defaults timeout: @config.rpcs.add_instance.timeout,
|
308
|
-
metadata: call_metadata
|
315
|
+
metadata: call_metadata,
|
316
|
+
retry_policy: @config.rpcs.add_instance.retry_policy
|
309
317
|
|
310
318
|
options.apply_defaults timeout: @config.timeout,
|
311
|
-
metadata: @config.metadata
|
319
|
+
metadata: @config.metadata,
|
320
|
+
retry_policy: @config.retry_policy
|
312
321
|
|
313
322
|
@target_pools_stub.add_instance request, options do |result, response|
|
314
323
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -323,12 +332,8 @@ module Google
|
|
323
332
|
yield result, response if block_given?
|
324
333
|
return result
|
325
334
|
end
|
326
|
-
rescue ::
|
327
|
-
|
328
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
329
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
330
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
331
|
-
end
|
335
|
+
rescue ::Gapic::Rest::Error => e
|
336
|
+
raise ::Google::Cloud::Error.from_error(e)
|
332
337
|
end
|
333
338
|
|
334
339
|
##
|
@@ -343,8 +348,6 @@ module Google
|
|
343
348
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
344
349
|
# @param options [::Gapic::CallOptions, ::Hash]
|
345
350
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
346
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
347
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
348
351
|
#
|
349
352
|
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil)
|
350
353
|
# Pass arguments to `aggregated_list` via keyword arguments. Note that at
|
@@ -383,29 +386,29 @@ module Google
|
|
383
386
|
# Customize the options with defaults
|
384
387
|
call_metadata = @config.rpcs.aggregated_list.metadata.to_h
|
385
388
|
|
386
|
-
# Set x-goog-api-client
|
389
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
387
390
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
388
391
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
389
392
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
390
393
|
transports_version_send: [:rest]
|
391
394
|
|
395
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
396
|
+
|
392
397
|
options.apply_defaults timeout: @config.rpcs.aggregated_list.timeout,
|
393
|
-
metadata: call_metadata
|
398
|
+
metadata: call_metadata,
|
399
|
+
retry_policy: @config.rpcs.aggregated_list.retry_policy
|
394
400
|
|
395
401
|
options.apply_defaults timeout: @config.timeout,
|
396
|
-
metadata: @config.metadata
|
402
|
+
metadata: @config.metadata,
|
403
|
+
retry_policy: @config.retry_policy
|
397
404
|
|
398
405
|
@target_pools_stub.aggregated_list request, options do |result, response|
|
399
406
|
result = ::Gapic::Rest::PagedEnumerable.new @target_pools_stub, :aggregated_list, "items", request, result, options
|
400
407
|
yield result, response if block_given?
|
401
408
|
return result
|
402
409
|
end
|
403
|
-
rescue ::
|
404
|
-
|
405
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
406
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
407
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
408
|
-
end
|
410
|
+
rescue ::Gapic::Rest::Error => e
|
411
|
+
raise ::Google::Cloud::Error.from_error(e)
|
409
412
|
end
|
410
413
|
|
411
414
|
##
|
@@ -420,8 +423,6 @@ module Google
|
|
420
423
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
421
424
|
# @param options [::Gapic::CallOptions, ::Hash]
|
422
425
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
423
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
424
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
425
426
|
#
|
426
427
|
# @overload delete(project: nil, region: nil, request_id: nil, target_pool: nil)
|
427
428
|
# Pass arguments to `delete` via keyword arguments. Note that at
|
@@ -454,17 +455,21 @@ module Google
|
|
454
455
|
# Customize the options with defaults
|
455
456
|
call_metadata = @config.rpcs.delete.metadata.to_h
|
456
457
|
|
457
|
-
# Set x-goog-api-client
|
458
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
458
459
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
459
460
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
460
461
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
461
462
|
transports_version_send: [:rest]
|
462
463
|
|
464
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
465
|
+
|
463
466
|
options.apply_defaults timeout: @config.rpcs.delete.timeout,
|
464
|
-
metadata: call_metadata
|
467
|
+
metadata: call_metadata,
|
468
|
+
retry_policy: @config.rpcs.delete.retry_policy
|
465
469
|
|
466
470
|
options.apply_defaults timeout: @config.timeout,
|
467
|
-
metadata: @config.metadata
|
471
|
+
metadata: @config.metadata,
|
472
|
+
retry_policy: @config.retry_policy
|
468
473
|
|
469
474
|
@target_pools_stub.delete request, options do |result, response|
|
470
475
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -479,12 +484,8 @@ module Google
|
|
479
484
|
yield result, response if block_given?
|
480
485
|
return result
|
481
486
|
end
|
482
|
-
rescue ::
|
483
|
-
|
484
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
485
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
486
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
487
|
-
end
|
487
|
+
rescue ::Gapic::Rest::Error => e
|
488
|
+
raise ::Google::Cloud::Error.from_error(e)
|
488
489
|
end
|
489
490
|
|
490
491
|
##
|
@@ -499,8 +500,6 @@ module Google
|
|
499
500
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
500
501
|
# @param options [::Gapic::CallOptions, ::Hash]
|
501
502
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
502
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
503
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
504
503
|
#
|
505
504
|
# @overload get(project: nil, region: nil, target_pool: nil)
|
506
505
|
# Pass arguments to `get` via keyword arguments. Note that at
|
@@ -531,28 +530,28 @@ module Google
|
|
531
530
|
# Customize the options with defaults
|
532
531
|
call_metadata = @config.rpcs.get.metadata.to_h
|
533
532
|
|
534
|
-
# Set x-goog-api-client
|
533
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
535
534
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
536
535
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
537
536
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
538
537
|
transports_version_send: [:rest]
|
539
538
|
|
539
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
540
|
+
|
540
541
|
options.apply_defaults timeout: @config.rpcs.get.timeout,
|
541
|
-
metadata: call_metadata
|
542
|
+
metadata: call_metadata,
|
543
|
+
retry_policy: @config.rpcs.get.retry_policy
|
542
544
|
|
543
545
|
options.apply_defaults timeout: @config.timeout,
|
544
|
-
metadata: @config.metadata
|
546
|
+
metadata: @config.metadata,
|
547
|
+
retry_policy: @config.retry_policy
|
545
548
|
|
546
549
|
@target_pools_stub.get request, options do |result, response|
|
547
550
|
yield result, response if block_given?
|
548
551
|
return result
|
549
552
|
end
|
550
|
-
rescue ::
|
551
|
-
|
552
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
553
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
554
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
555
|
-
end
|
553
|
+
rescue ::Gapic::Rest::Error => e
|
554
|
+
raise ::Google::Cloud::Error.from_error(e)
|
556
555
|
end
|
557
556
|
|
558
557
|
##
|
@@ -567,8 +566,6 @@ module Google
|
|
567
566
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
568
567
|
# @param options [::Gapic::CallOptions, ::Hash]
|
569
568
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
570
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
571
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
572
569
|
#
|
573
570
|
# @overload get_health(instance_reference_resource: nil, project: nil, region: nil, target_pool: nil)
|
574
571
|
# Pass arguments to `get_health` via keyword arguments. Note that at
|
@@ -601,28 +598,28 @@ module Google
|
|
601
598
|
# Customize the options with defaults
|
602
599
|
call_metadata = @config.rpcs.get_health.metadata.to_h
|
603
600
|
|
604
|
-
# Set x-goog-api-client
|
601
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
605
602
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
606
603
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
607
604
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
608
605
|
transports_version_send: [:rest]
|
609
606
|
|
607
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
608
|
+
|
610
609
|
options.apply_defaults timeout: @config.rpcs.get_health.timeout,
|
611
|
-
metadata: call_metadata
|
610
|
+
metadata: call_metadata,
|
611
|
+
retry_policy: @config.rpcs.get_health.retry_policy
|
612
612
|
|
613
613
|
options.apply_defaults timeout: @config.timeout,
|
614
|
-
metadata: @config.metadata
|
614
|
+
metadata: @config.metadata,
|
615
|
+
retry_policy: @config.retry_policy
|
615
616
|
|
616
617
|
@target_pools_stub.get_health request, options do |result, response|
|
617
618
|
yield result, response if block_given?
|
618
619
|
return result
|
619
620
|
end
|
620
|
-
rescue ::
|
621
|
-
|
622
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
623
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
624
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
625
|
-
end
|
621
|
+
rescue ::Gapic::Rest::Error => e
|
622
|
+
raise ::Google::Cloud::Error.from_error(e)
|
626
623
|
end
|
627
624
|
|
628
625
|
##
|
@@ -637,8 +634,6 @@ module Google
|
|
637
634
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
638
635
|
# @param options [::Gapic::CallOptions, ::Hash]
|
639
636
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
640
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
641
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
642
637
|
#
|
643
638
|
# @overload insert(project: nil, region: nil, request_id: nil, target_pool_resource: nil)
|
644
639
|
# Pass arguments to `insert` via keyword arguments. Note that at
|
@@ -671,17 +666,21 @@ module Google
|
|
671
666
|
# Customize the options with defaults
|
672
667
|
call_metadata = @config.rpcs.insert.metadata.to_h
|
673
668
|
|
674
|
-
# Set x-goog-api-client
|
669
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
675
670
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
676
671
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
677
672
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
678
673
|
transports_version_send: [:rest]
|
679
674
|
|
675
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
676
|
+
|
680
677
|
options.apply_defaults timeout: @config.rpcs.insert.timeout,
|
681
|
-
metadata: call_metadata
|
678
|
+
metadata: call_metadata,
|
679
|
+
retry_policy: @config.rpcs.insert.retry_policy
|
682
680
|
|
683
681
|
options.apply_defaults timeout: @config.timeout,
|
684
|
-
metadata: @config.metadata
|
682
|
+
metadata: @config.metadata,
|
683
|
+
retry_policy: @config.retry_policy
|
685
684
|
|
686
685
|
@target_pools_stub.insert request, options do |result, response|
|
687
686
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -696,12 +695,8 @@ module Google
|
|
696
695
|
yield result, response if block_given?
|
697
696
|
return result
|
698
697
|
end
|
699
|
-
rescue ::
|
700
|
-
|
701
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
702
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
703
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
704
|
-
end
|
698
|
+
rescue ::Gapic::Rest::Error => e
|
699
|
+
raise ::Google::Cloud::Error.from_error(e)
|
705
700
|
end
|
706
701
|
|
707
702
|
##
|
@@ -716,8 +711,6 @@ module Google
|
|
716
711
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
717
712
|
# @param options [::Gapic::CallOptions, ::Hash]
|
718
713
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
719
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
720
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
721
714
|
#
|
722
715
|
# @overload list(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil)
|
723
716
|
# Pass arguments to `list` via keyword arguments. Note that at
|
@@ -756,29 +749,29 @@ module Google
|
|
756
749
|
# Customize the options with defaults
|
757
750
|
call_metadata = @config.rpcs.list.metadata.to_h
|
758
751
|
|
759
|
-
# Set x-goog-api-client
|
752
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
760
753
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
761
754
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
762
755
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
763
756
|
transports_version_send: [:rest]
|
764
757
|
|
758
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
759
|
+
|
765
760
|
options.apply_defaults timeout: @config.rpcs.list.timeout,
|
766
|
-
metadata: call_metadata
|
761
|
+
metadata: call_metadata,
|
762
|
+
retry_policy: @config.rpcs.list.retry_policy
|
767
763
|
|
768
764
|
options.apply_defaults timeout: @config.timeout,
|
769
|
-
metadata: @config.metadata
|
765
|
+
metadata: @config.metadata,
|
766
|
+
retry_policy: @config.retry_policy
|
770
767
|
|
771
768
|
@target_pools_stub.list request, options do |result, response|
|
772
769
|
result = ::Gapic::Rest::PagedEnumerable.new @target_pools_stub, :list, "items", request, result, options
|
773
770
|
yield result, response if block_given?
|
774
771
|
return result
|
775
772
|
end
|
776
|
-
rescue ::
|
777
|
-
|
778
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
779
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
780
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
781
|
-
end
|
773
|
+
rescue ::Gapic::Rest::Error => e
|
774
|
+
raise ::Google::Cloud::Error.from_error(e)
|
782
775
|
end
|
783
776
|
|
784
777
|
##
|
@@ -793,8 +786,6 @@ module Google
|
|
793
786
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
794
787
|
# @param options [::Gapic::CallOptions, ::Hash]
|
795
788
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
796
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
797
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
798
789
|
#
|
799
790
|
# @overload remove_health_check(project: nil, region: nil, request_id: nil, target_pool: nil, target_pools_remove_health_check_request_resource: nil)
|
800
791
|
# Pass arguments to `remove_health_check` via keyword arguments. Note that at
|
@@ -829,17 +820,21 @@ module Google
|
|
829
820
|
# Customize the options with defaults
|
830
821
|
call_metadata = @config.rpcs.remove_health_check.metadata.to_h
|
831
822
|
|
832
|
-
# Set x-goog-api-client
|
823
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
833
824
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
834
825
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
835
826
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
836
827
|
transports_version_send: [:rest]
|
837
828
|
|
829
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
830
|
+
|
838
831
|
options.apply_defaults timeout: @config.rpcs.remove_health_check.timeout,
|
839
|
-
metadata: call_metadata
|
832
|
+
metadata: call_metadata,
|
833
|
+
retry_policy: @config.rpcs.remove_health_check.retry_policy
|
840
834
|
|
841
835
|
options.apply_defaults timeout: @config.timeout,
|
842
|
-
metadata: @config.metadata
|
836
|
+
metadata: @config.metadata,
|
837
|
+
retry_policy: @config.retry_policy
|
843
838
|
|
844
839
|
@target_pools_stub.remove_health_check request, options do |result, response|
|
845
840
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -854,12 +849,8 @@ module Google
|
|
854
849
|
yield result, response if block_given?
|
855
850
|
return result
|
856
851
|
end
|
857
|
-
rescue ::
|
858
|
-
|
859
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
860
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
861
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
862
|
-
end
|
852
|
+
rescue ::Gapic::Rest::Error => e
|
853
|
+
raise ::Google::Cloud::Error.from_error(e)
|
863
854
|
end
|
864
855
|
|
865
856
|
##
|
@@ -874,8 +865,6 @@ module Google
|
|
874
865
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
875
866
|
# @param options [::Gapic::CallOptions, ::Hash]
|
876
867
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
877
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
878
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
879
868
|
#
|
880
869
|
# @overload remove_instance(project: nil, region: nil, request_id: nil, target_pool: nil, target_pools_remove_instance_request_resource: nil)
|
881
870
|
# Pass arguments to `remove_instance` via keyword arguments. Note that at
|
@@ -910,17 +899,21 @@ module Google
|
|
910
899
|
# Customize the options with defaults
|
911
900
|
call_metadata = @config.rpcs.remove_instance.metadata.to_h
|
912
901
|
|
913
|
-
# Set x-goog-api-client
|
902
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
914
903
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
915
904
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
916
905
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
917
906
|
transports_version_send: [:rest]
|
918
907
|
|
908
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
909
|
+
|
919
910
|
options.apply_defaults timeout: @config.rpcs.remove_instance.timeout,
|
920
|
-
metadata: call_metadata
|
911
|
+
metadata: call_metadata,
|
912
|
+
retry_policy: @config.rpcs.remove_instance.retry_policy
|
921
913
|
|
922
914
|
options.apply_defaults timeout: @config.timeout,
|
923
|
-
metadata: @config.metadata
|
915
|
+
metadata: @config.metadata,
|
916
|
+
retry_policy: @config.retry_policy
|
924
917
|
|
925
918
|
@target_pools_stub.remove_instance request, options do |result, response|
|
926
919
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -935,12 +928,8 @@ module Google
|
|
935
928
|
yield result, response if block_given?
|
936
929
|
return result
|
937
930
|
end
|
938
|
-
rescue ::
|
939
|
-
|
940
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
941
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
942
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
943
|
-
end
|
931
|
+
rescue ::Gapic::Rest::Error => e
|
932
|
+
raise ::Google::Cloud::Error.from_error(e)
|
944
933
|
end
|
945
934
|
|
946
935
|
##
|
@@ -955,8 +944,6 @@ module Google
|
|
955
944
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
956
945
|
# @param options [::Gapic::CallOptions, ::Hash]
|
957
946
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
958
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
959
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
960
947
|
#
|
961
948
|
# @overload set_backup(failover_ratio: nil, project: nil, region: nil, request_id: nil, target_pool: nil, target_reference_resource: nil)
|
962
949
|
# Pass arguments to `set_backup` via keyword arguments. Note that at
|
@@ -993,17 +980,21 @@ module Google
|
|
993
980
|
# Customize the options with defaults
|
994
981
|
call_metadata = @config.rpcs.set_backup.metadata.to_h
|
995
982
|
|
996
|
-
# Set x-goog-api-client
|
983
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
997
984
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
998
985
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
999
986
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
1000
987
|
transports_version_send: [:rest]
|
1001
988
|
|
989
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
990
|
+
|
1002
991
|
options.apply_defaults timeout: @config.rpcs.set_backup.timeout,
|
1003
|
-
metadata: call_metadata
|
992
|
+
metadata: call_metadata,
|
993
|
+
retry_policy: @config.rpcs.set_backup.retry_policy
|
1004
994
|
|
1005
995
|
options.apply_defaults timeout: @config.timeout,
|
1006
|
-
metadata: @config.metadata
|
996
|
+
metadata: @config.metadata,
|
997
|
+
retry_policy: @config.retry_policy
|
1007
998
|
|
1008
999
|
@target_pools_stub.set_backup request, options do |result, response|
|
1009
1000
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -1018,36 +1009,38 @@ module Google
|
|
1018
1009
|
yield result, response if block_given?
|
1019
1010
|
return result
|
1020
1011
|
end
|
1021
|
-
rescue ::
|
1022
|
-
|
1023
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
1024
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
1025
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
1026
|
-
end
|
1012
|
+
rescue ::Gapic::Rest::Error => e
|
1013
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1027
1014
|
end
|
1028
1015
|
|
1029
1016
|
##
|
1030
1017
|
# Configuration class for the TargetPools REST API.
|
1031
1018
|
#
|
1032
1019
|
# This class represents the configuration for TargetPools REST,
|
1033
|
-
# providing control over
|
1020
|
+
# providing control over timeouts, retry behavior, logging, transport
|
1021
|
+
# parameters, and other low-level controls. Certain parameters can also be
|
1022
|
+
# applied individually to specific RPCs. See
|
1023
|
+
# {::Google::Cloud::Compute::V1::TargetPools::Rest::Client::Configuration::Rpcs}
|
1024
|
+
# for a list of RPCs that can be configured independently.
|
1034
1025
|
#
|
1035
1026
|
# Configuration can be applied globally to all clients, or to a single client
|
1036
1027
|
# on construction.
|
1037
1028
|
#
|
1038
|
-
#
|
1039
|
-
#
|
1040
|
-
# To modify the global config, setting the timeout for all calls to 10 seconds:
|
1041
|
-
#
|
1042
|
-
# ::Google::Cloud::Compute::V1::TargetPools::Client.configure do |config|
|
1043
|
-
# config.timeout = 10.0
|
1044
|
-
# end
|
1029
|
+
# @example
|
1045
1030
|
#
|
1046
|
-
#
|
1031
|
+
# # Modify the global config, setting the timeout for
|
1032
|
+
# # add_health_check to 20 seconds,
|
1033
|
+
# # and all remaining timeouts to 10 seconds.
|
1034
|
+
# ::Google::Cloud::Compute::V1::TargetPools::Rest::Client.configure do |config|
|
1035
|
+
# config.timeout = 10.0
|
1036
|
+
# config.rpcs.add_health_check.timeout = 20.0
|
1037
|
+
# end
|
1047
1038
|
#
|
1048
|
-
#
|
1049
|
-
#
|
1050
|
-
#
|
1039
|
+
# # Apply the above configuration only to a new client.
|
1040
|
+
# client = ::Google::Cloud::Compute::V1::TargetPools::Rest::Client.new do |config|
|
1041
|
+
# config.timeout = 10.0
|
1042
|
+
# config.rpcs.add_health_check.timeout = 20.0
|
1043
|
+
# end
|
1051
1044
|
#
|
1052
1045
|
# @!attribute [rw] endpoint
|
1053
1046
|
# The hostname or hostname:port of the service endpoint.
|
@@ -1076,8 +1069,19 @@ module Google
|
|
1076
1069
|
# The call timeout in seconds.
|
1077
1070
|
# @return [::Numeric]
|
1078
1071
|
# @!attribute [rw] metadata
|
1079
|
-
# Additional
|
1072
|
+
# Additional headers to be sent with the call.
|
1080
1073
|
# @return [::Hash{::Symbol=>::String}]
|
1074
|
+
# @!attribute [rw] retry_policy
|
1075
|
+
# The retry policy. The value is a hash with the following keys:
|
1076
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
1077
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
1078
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
1079
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
1080
|
+
# trigger a retry.
|
1081
|
+
# @return [::Hash]
|
1082
|
+
# @!attribute [rw] quota_project
|
1083
|
+
# A separate project against which to charge quota.
|
1084
|
+
# @return [::String]
|
1081
1085
|
#
|
1082
1086
|
class Configuration
|
1083
1087
|
extend ::Gapic::Config
|
@@ -1092,6 +1096,8 @@ module Google
|
|
1092
1096
|
config_attr :lib_version, nil, ::String, nil
|
1093
1097
|
config_attr :timeout, nil, ::Numeric, nil
|
1094
1098
|
config_attr :metadata, nil, ::Hash, nil
|
1099
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
1100
|
+
config_attr :quota_project, nil, ::String, nil
|
1095
1101
|
|
1096
1102
|
# @private
|
1097
1103
|
def initialize parent_config = nil
|
@@ -1120,9 +1126,14 @@ module Google
|
|
1120
1126
|
# the following configuration fields:
|
1121
1127
|
#
|
1122
1128
|
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
1123
|
-
#
|
1124
|
-
#
|
1125
|
-
#
|
1129
|
+
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
|
1130
|
+
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
1131
|
+
# include the following keys:
|
1132
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
1133
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
1134
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
1135
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
1136
|
+
# trigger a retry.
|
1126
1137
|
#
|
1127
1138
|
class Rpcs
|
1128
1139
|
##
|