google-cloud-compute-v1 1.8.0 → 1.9.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 +194 -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 +536 -28
- data/proto_docs/google/protobuf/duration.rb +98 -0
- metadata +14 -5
@@ -136,13 +136,22 @@ module Google
|
|
136
136
|
|
137
137
|
# Create credentials
|
138
138
|
credentials = @config.credentials
|
139
|
-
|
139
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
140
|
+
# but only if the default endpoint does not have a region prefix.
|
141
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
142
|
+
!@config.endpoint.split(".").first.include?("-")
|
143
|
+
credentials ||= Credentials.default scope: @config.scope,
|
144
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
140
145
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
141
146
|
credentials = Credentials.new credentials, scope: @config.scope
|
142
147
|
end
|
143
148
|
|
149
|
+
@quota_project_id = @config.quota_project
|
150
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
151
|
+
|
144
152
|
@region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
|
145
153
|
config.credentials = credentials
|
154
|
+
config.quota_project = @quota_project_id
|
146
155
|
config.endpoint = @config.endpoint
|
147
156
|
end
|
148
157
|
|
@@ -170,8 +179,6 @@ module Google
|
|
170
179
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
171
180
|
# @param options [::Gapic::CallOptions, ::Hash]
|
172
181
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
173
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
174
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
175
182
|
#
|
176
183
|
# @overload delete(project: nil, region: nil, request_id: nil, url_map: nil)
|
177
184
|
# Pass arguments to `delete` via keyword arguments. Note that at
|
@@ -204,17 +211,21 @@ module Google
|
|
204
211
|
# Customize the options with defaults
|
205
212
|
call_metadata = @config.rpcs.delete.metadata.to_h
|
206
213
|
|
207
|
-
# Set x-goog-api-client
|
214
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
208
215
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
209
216
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
210
217
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
211
218
|
transports_version_send: [:rest]
|
212
219
|
|
220
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
221
|
+
|
213
222
|
options.apply_defaults timeout: @config.rpcs.delete.timeout,
|
214
|
-
metadata: call_metadata
|
223
|
+
metadata: call_metadata,
|
224
|
+
retry_policy: @config.rpcs.delete.retry_policy
|
215
225
|
|
216
226
|
options.apply_defaults timeout: @config.timeout,
|
217
|
-
metadata: @config.metadata
|
227
|
+
metadata: @config.metadata,
|
228
|
+
retry_policy: @config.retry_policy
|
218
229
|
|
219
230
|
@region_url_maps_stub.delete request, options do |result, response|
|
220
231
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -229,12 +240,8 @@ module Google
|
|
229
240
|
yield result, response if block_given?
|
230
241
|
return result
|
231
242
|
end
|
232
|
-
rescue ::
|
233
|
-
|
234
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
235
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
236
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
237
|
-
end
|
243
|
+
rescue ::Gapic::Rest::Error => e
|
244
|
+
raise ::Google::Cloud::Error.from_error(e)
|
238
245
|
end
|
239
246
|
|
240
247
|
##
|
@@ -249,8 +256,6 @@ module Google
|
|
249
256
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
250
257
|
# @param options [::Gapic::CallOptions, ::Hash]
|
251
258
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
252
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
253
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
254
259
|
#
|
255
260
|
# @overload get(project: nil, region: nil, url_map: nil)
|
256
261
|
# Pass arguments to `get` via keyword arguments. Note that at
|
@@ -281,28 +286,28 @@ module Google
|
|
281
286
|
# Customize the options with defaults
|
282
287
|
call_metadata = @config.rpcs.get.metadata.to_h
|
283
288
|
|
284
|
-
# Set x-goog-api-client
|
289
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
285
290
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
286
291
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
287
292
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
288
293
|
transports_version_send: [:rest]
|
289
294
|
|
295
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
296
|
+
|
290
297
|
options.apply_defaults timeout: @config.rpcs.get.timeout,
|
291
|
-
metadata: call_metadata
|
298
|
+
metadata: call_metadata,
|
299
|
+
retry_policy: @config.rpcs.get.retry_policy
|
292
300
|
|
293
301
|
options.apply_defaults timeout: @config.timeout,
|
294
|
-
metadata: @config.metadata
|
302
|
+
metadata: @config.metadata,
|
303
|
+
retry_policy: @config.retry_policy
|
295
304
|
|
296
305
|
@region_url_maps_stub.get request, options do |result, response|
|
297
306
|
yield result, response if block_given?
|
298
307
|
return result
|
299
308
|
end
|
300
|
-
rescue ::
|
301
|
-
|
302
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
303
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
304
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
305
|
-
end
|
309
|
+
rescue ::Gapic::Rest::Error => e
|
310
|
+
raise ::Google::Cloud::Error.from_error(e)
|
306
311
|
end
|
307
312
|
|
308
313
|
##
|
@@ -317,8 +322,6 @@ module Google
|
|
317
322
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
318
323
|
# @param options [::Gapic::CallOptions, ::Hash]
|
319
324
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
320
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
321
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
322
325
|
#
|
323
326
|
# @overload insert(project: nil, region: nil, request_id: nil, url_map_resource: nil)
|
324
327
|
# Pass arguments to `insert` via keyword arguments. Note that at
|
@@ -351,17 +354,21 @@ module Google
|
|
351
354
|
# Customize the options with defaults
|
352
355
|
call_metadata = @config.rpcs.insert.metadata.to_h
|
353
356
|
|
354
|
-
# Set x-goog-api-client
|
357
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
355
358
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
356
359
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
357
360
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
358
361
|
transports_version_send: [:rest]
|
359
362
|
|
363
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
364
|
+
|
360
365
|
options.apply_defaults timeout: @config.rpcs.insert.timeout,
|
361
|
-
metadata: call_metadata
|
366
|
+
metadata: call_metadata,
|
367
|
+
retry_policy: @config.rpcs.insert.retry_policy
|
362
368
|
|
363
369
|
options.apply_defaults timeout: @config.timeout,
|
364
|
-
metadata: @config.metadata
|
370
|
+
metadata: @config.metadata,
|
371
|
+
retry_policy: @config.retry_policy
|
365
372
|
|
366
373
|
@region_url_maps_stub.insert request, options do |result, response|
|
367
374
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -376,12 +383,8 @@ module Google
|
|
376
383
|
yield result, response if block_given?
|
377
384
|
return result
|
378
385
|
end
|
379
|
-
rescue ::
|
380
|
-
|
381
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
382
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
383
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
384
|
-
end
|
386
|
+
rescue ::Gapic::Rest::Error => e
|
387
|
+
raise ::Google::Cloud::Error.from_error(e)
|
385
388
|
end
|
386
389
|
|
387
390
|
##
|
@@ -396,8 +399,6 @@ module Google
|
|
396
399
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
397
400
|
# @param options [::Gapic::CallOptions, ::Hash]
|
398
401
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
399
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
400
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
401
402
|
#
|
402
403
|
# @overload list(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil)
|
403
404
|
# Pass arguments to `list` via keyword arguments. Note that at
|
@@ -436,29 +437,29 @@ module Google
|
|
436
437
|
# Customize the options with defaults
|
437
438
|
call_metadata = @config.rpcs.list.metadata.to_h
|
438
439
|
|
439
|
-
# Set x-goog-api-client
|
440
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
440
441
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
441
442
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
442
443
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
443
444
|
transports_version_send: [:rest]
|
444
445
|
|
446
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
447
|
+
|
445
448
|
options.apply_defaults timeout: @config.rpcs.list.timeout,
|
446
|
-
metadata: call_metadata
|
449
|
+
metadata: call_metadata,
|
450
|
+
retry_policy: @config.rpcs.list.retry_policy
|
447
451
|
|
448
452
|
options.apply_defaults timeout: @config.timeout,
|
449
|
-
metadata: @config.metadata
|
453
|
+
metadata: @config.metadata,
|
454
|
+
retry_policy: @config.retry_policy
|
450
455
|
|
451
456
|
@region_url_maps_stub.list request, options do |result, response|
|
452
457
|
result = ::Gapic::Rest::PagedEnumerable.new @region_url_maps_stub, :list, "items", request, result, options
|
453
458
|
yield result, response if block_given?
|
454
459
|
return result
|
455
460
|
end
|
456
|
-
rescue ::
|
457
|
-
|
458
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
459
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
460
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
461
|
-
end
|
461
|
+
rescue ::Gapic::Rest::Error => e
|
462
|
+
raise ::Google::Cloud::Error.from_error(e)
|
462
463
|
end
|
463
464
|
|
464
465
|
##
|
@@ -473,8 +474,6 @@ module Google
|
|
473
474
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
474
475
|
# @param options [::Gapic::CallOptions, ::Hash]
|
475
476
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
476
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
477
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
478
477
|
#
|
479
478
|
# @overload patch(project: nil, region: nil, request_id: nil, url_map: nil, url_map_resource: nil)
|
480
479
|
# Pass arguments to `patch` via keyword arguments. Note that at
|
@@ -509,17 +508,21 @@ module Google
|
|
509
508
|
# Customize the options with defaults
|
510
509
|
call_metadata = @config.rpcs.patch.metadata.to_h
|
511
510
|
|
512
|
-
# Set x-goog-api-client
|
511
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
513
512
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
514
513
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
515
514
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
516
515
|
transports_version_send: [:rest]
|
517
516
|
|
517
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
518
|
+
|
518
519
|
options.apply_defaults timeout: @config.rpcs.patch.timeout,
|
519
|
-
metadata: call_metadata
|
520
|
+
metadata: call_metadata,
|
521
|
+
retry_policy: @config.rpcs.patch.retry_policy
|
520
522
|
|
521
523
|
options.apply_defaults timeout: @config.timeout,
|
522
|
-
metadata: @config.metadata
|
524
|
+
metadata: @config.metadata,
|
525
|
+
retry_policy: @config.retry_policy
|
523
526
|
|
524
527
|
@region_url_maps_stub.patch request, options do |result, response|
|
525
528
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -534,12 +537,8 @@ module Google
|
|
534
537
|
yield result, response if block_given?
|
535
538
|
return result
|
536
539
|
end
|
537
|
-
rescue ::
|
538
|
-
|
539
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
540
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
541
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
542
|
-
end
|
540
|
+
rescue ::Gapic::Rest::Error => e
|
541
|
+
raise ::Google::Cloud::Error.from_error(e)
|
543
542
|
end
|
544
543
|
|
545
544
|
##
|
@@ -554,8 +553,6 @@ module Google
|
|
554
553
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
555
554
|
# @param options [::Gapic::CallOptions, ::Hash]
|
556
555
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
557
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
558
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
559
556
|
#
|
560
557
|
# @overload update(project: nil, region: nil, request_id: nil, url_map: nil, url_map_resource: nil)
|
561
558
|
# Pass arguments to `update` via keyword arguments. Note that at
|
@@ -590,17 +587,21 @@ module Google
|
|
590
587
|
# Customize the options with defaults
|
591
588
|
call_metadata = @config.rpcs.update.metadata.to_h
|
592
589
|
|
593
|
-
# Set x-goog-api-client
|
590
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
594
591
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
595
592
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
596
593
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
597
594
|
transports_version_send: [:rest]
|
598
595
|
|
596
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
597
|
+
|
599
598
|
options.apply_defaults timeout: @config.rpcs.update.timeout,
|
600
|
-
metadata: call_metadata
|
599
|
+
metadata: call_metadata,
|
600
|
+
retry_policy: @config.rpcs.update.retry_policy
|
601
601
|
|
602
602
|
options.apply_defaults timeout: @config.timeout,
|
603
|
-
metadata: @config.metadata
|
603
|
+
metadata: @config.metadata,
|
604
|
+
retry_policy: @config.retry_policy
|
604
605
|
|
605
606
|
@region_url_maps_stub.update request, options do |result, response|
|
606
607
|
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
@@ -615,12 +616,8 @@ module Google
|
|
615
616
|
yield result, response if block_given?
|
616
617
|
return result
|
617
618
|
end
|
618
|
-
rescue ::
|
619
|
-
|
620
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
621
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
622
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
623
|
-
end
|
619
|
+
rescue ::Gapic::Rest::Error => e
|
620
|
+
raise ::Google::Cloud::Error.from_error(e)
|
624
621
|
end
|
625
622
|
|
626
623
|
##
|
@@ -635,8 +632,6 @@ module Google
|
|
635
632
|
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
636
633
|
# @param options [::Gapic::CallOptions, ::Hash]
|
637
634
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
638
|
-
# Note: currently retry functionality is not implemented. While it is possible
|
639
|
-
# to set it using ::Gapic::CallOptions, it will not be applied
|
640
635
|
#
|
641
636
|
# @overload validate(project: nil, region: nil, region_url_maps_validate_request_resource: nil, url_map: nil)
|
642
637
|
# Pass arguments to `validate` via keyword arguments. Note that at
|
@@ -669,52 +664,58 @@ module Google
|
|
669
664
|
# Customize the options with defaults
|
670
665
|
call_metadata = @config.rpcs.validate.metadata.to_h
|
671
666
|
|
672
|
-
# Set x-goog-api-client
|
667
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
673
668
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
674
669
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
675
670
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
676
671
|
transports_version_send: [:rest]
|
677
672
|
|
673
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
674
|
+
|
678
675
|
options.apply_defaults timeout: @config.rpcs.validate.timeout,
|
679
|
-
metadata: call_metadata
|
676
|
+
metadata: call_metadata,
|
677
|
+
retry_policy: @config.rpcs.validate.retry_policy
|
680
678
|
|
681
679
|
options.apply_defaults timeout: @config.timeout,
|
682
|
-
metadata: @config.metadata
|
680
|
+
metadata: @config.metadata,
|
681
|
+
retry_policy: @config.retry_policy
|
683
682
|
|
684
683
|
@region_url_maps_stub.validate request, options do |result, response|
|
685
684
|
yield result, response if block_given?
|
686
685
|
return result
|
687
686
|
end
|
688
|
-
rescue ::
|
689
|
-
|
690
|
-
raise ::Gapic::Rest::Error.wrap_faraday_error e
|
691
|
-
rescue ::Gapic::Rest::Error => gapic_error
|
692
|
-
raise ::Google::Cloud::Error.from_error gapic_error
|
693
|
-
end
|
687
|
+
rescue ::Gapic::Rest::Error => e
|
688
|
+
raise ::Google::Cloud::Error.from_error(e)
|
694
689
|
end
|
695
690
|
|
696
691
|
##
|
697
692
|
# Configuration class for the RegionUrlMaps REST API.
|
698
693
|
#
|
699
694
|
# This class represents the configuration for RegionUrlMaps REST,
|
700
|
-
# providing control over
|
695
|
+
# providing control over timeouts, retry behavior, logging, transport
|
696
|
+
# parameters, and other low-level controls. Certain parameters can also be
|
697
|
+
# applied individually to specific RPCs. See
|
698
|
+
# {::Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client::Configuration::Rpcs}
|
699
|
+
# for a list of RPCs that can be configured independently.
|
701
700
|
#
|
702
701
|
# Configuration can be applied globally to all clients, or to a single client
|
703
702
|
# on construction.
|
704
703
|
#
|
705
|
-
#
|
706
|
-
#
|
707
|
-
# To modify the global config, setting the timeout for all calls to 10 seconds:
|
708
|
-
#
|
709
|
-
# ::Google::Cloud::Compute::V1::RegionUrlMaps::Client.configure do |config|
|
710
|
-
# config.timeout = 10.0
|
711
|
-
# end
|
704
|
+
# @example
|
712
705
|
#
|
713
|
-
#
|
706
|
+
# # Modify the global config, setting the timeout for
|
707
|
+
# # delete to 20 seconds,
|
708
|
+
# # and all remaining timeouts to 10 seconds.
|
709
|
+
# ::Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client.configure do |config|
|
710
|
+
# config.timeout = 10.0
|
711
|
+
# config.rpcs.delete.timeout = 20.0
|
712
|
+
# end
|
714
713
|
#
|
715
|
-
#
|
716
|
-
#
|
717
|
-
#
|
714
|
+
# # Apply the above configuration only to a new client.
|
715
|
+
# client = ::Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client.new do |config|
|
716
|
+
# config.timeout = 10.0
|
717
|
+
# config.rpcs.delete.timeout = 20.0
|
718
|
+
# end
|
718
719
|
#
|
719
720
|
# @!attribute [rw] endpoint
|
720
721
|
# The hostname or hostname:port of the service endpoint.
|
@@ -743,8 +744,19 @@ module Google
|
|
743
744
|
# The call timeout in seconds.
|
744
745
|
# @return [::Numeric]
|
745
746
|
# @!attribute [rw] metadata
|
746
|
-
# Additional
|
747
|
+
# Additional headers to be sent with the call.
|
747
748
|
# @return [::Hash{::Symbol=>::String}]
|
749
|
+
# @!attribute [rw] retry_policy
|
750
|
+
# The retry policy. The value is a hash with the following keys:
|
751
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
752
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
753
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
754
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
755
|
+
# trigger a retry.
|
756
|
+
# @return [::Hash]
|
757
|
+
# @!attribute [rw] quota_project
|
758
|
+
# A separate project against which to charge quota.
|
759
|
+
# @return [::String]
|
748
760
|
#
|
749
761
|
class Configuration
|
750
762
|
extend ::Gapic::Config
|
@@ -759,6 +771,8 @@ module Google
|
|
759
771
|
config_attr :lib_version, nil, ::String, nil
|
760
772
|
config_attr :timeout, nil, ::Numeric, nil
|
761
773
|
config_attr :metadata, nil, ::Hash, nil
|
774
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
775
|
+
config_attr :quota_project, nil, ::String, nil
|
762
776
|
|
763
777
|
# @private
|
764
778
|
def initialize parent_config = nil
|
@@ -787,9 +801,14 @@ module Google
|
|
787
801
|
# the following configuration fields:
|
788
802
|
#
|
789
803
|
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
790
|
-
#
|
791
|
-
#
|
792
|
-
#
|
804
|
+
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
|
805
|
+
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
806
|
+
# include the following keys:
|
807
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
808
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
809
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
810
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
811
|
+
# trigger a retry.
|
793
812
|
#
|
794
813
|
class Rpcs
|
795
814
|
##
|
@@ -35,7 +35,9 @@ module Google
|
|
35
35
|
# the REST modules only when it's required.
|
36
36
|
require "gapic/rest"
|
37
37
|
|
38
|
-
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, credentials: credentials,
|
38
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, credentials: credentials,
|
39
|
+
numeric_enums: false,
|
40
|
+
raise_faraday_errors: false
|
39
41
|
end
|
40
42
|
|
41
43
|
##
|
@@ -55,7 +57,7 @@ module Google
|
|
55
57
|
def delete request_pb, options = nil
|
56
58
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
57
59
|
|
58
|
-
verb, uri, query_string_params, body = transcode_delete_request request_pb
|
60
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_request request_pb
|
59
61
|
query_string_params = if query_string_params.any?
|
60
62
|
query_string_params.to_h { |p| p.split("=", 2) }
|
61
63
|
else
|
@@ -92,7 +94,7 @@ module Google
|
|
92
94
|
def get request_pb, options = nil
|
93
95
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
94
96
|
|
95
|
-
verb, uri, query_string_params, body = transcode_get_request request_pb
|
97
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_request request_pb
|
96
98
|
query_string_params = if query_string_params.any?
|
97
99
|
query_string_params.to_h { |p| p.split("=", 2) }
|
98
100
|
else
|
@@ -129,7 +131,7 @@ module Google
|
|
129
131
|
def insert request_pb, options = nil
|
130
132
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
131
133
|
|
132
|
-
verb, uri, query_string_params, body = transcode_insert_request request_pb
|
134
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_insert_request request_pb
|
133
135
|
query_string_params = if query_string_params.any?
|
134
136
|
query_string_params.to_h { |p| p.split("=", 2) }
|
135
137
|
else
|
@@ -166,7 +168,7 @@ module Google
|
|
166
168
|
def list request_pb, options = nil
|
167
169
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
168
170
|
|
169
|
-
verb, uri, query_string_params, body = transcode_list_request request_pb
|
171
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_request request_pb
|
170
172
|
query_string_params = if query_string_params.any?
|
171
173
|
query_string_params.to_h { |p| p.split("=", 2) }
|
172
174
|
else
|
@@ -203,7 +205,7 @@ module Google
|
|
203
205
|
def patch request_pb, options = nil
|
204
206
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
205
207
|
|
206
|
-
verb, uri, query_string_params, body = transcode_patch_request request_pb
|
208
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_patch_request request_pb
|
207
209
|
query_string_params = if query_string_params.any?
|
208
210
|
query_string_params.to_h { |p| p.split("=", 2) }
|
209
211
|
else
|
@@ -240,7 +242,7 @@ module Google
|
|
240
242
|
def update request_pb, options = nil
|
241
243
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
242
244
|
|
243
|
-
verb, uri, query_string_params, body = transcode_update_request request_pb
|
245
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_request request_pb
|
244
246
|
query_string_params = if query_string_params.any?
|
245
247
|
query_string_params.to_h { |p| p.split("=", 2) }
|
246
248
|
else
|
@@ -277,7 +279,7 @@ module Google
|
|
277
279
|
def validate request_pb, options = nil
|
278
280
|
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
279
281
|
|
280
|
-
verb, uri, query_string_params, body = transcode_validate_request request_pb
|
282
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_validate_request request_pb
|
281
283
|
query_string_params = if query_string_params.any?
|
282
284
|
query_string_params.to_h { |p| p.split("=", 2) }
|
283
285
|
else
|
@@ -297,9 +299,6 @@ module Google
|
|
297
299
|
result
|
298
300
|
end
|
299
301
|
|
300
|
-
|
301
|
-
private
|
302
|
-
|
303
302
|
##
|
304
303
|
# @private
|
305
304
|
#
|
@@ -309,7 +308,7 @@ module Google
|
|
309
308
|
# A request object representing the call parameters. Required.
|
310
309
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
311
310
|
# Uri, Body, Query string parameters
|
312
|
-
def transcode_delete_request request_pb
|
311
|
+
def self.transcode_delete_request request_pb
|
313
312
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
314
313
|
.with_bindings(
|
315
314
|
uri_method: :delete,
|
@@ -332,7 +331,7 @@ module Google
|
|
332
331
|
# A request object representing the call parameters. Required.
|
333
332
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
334
333
|
# Uri, Body, Query string parameters
|
335
|
-
def transcode_get_request request_pb
|
334
|
+
def self.transcode_get_request request_pb
|
336
335
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
337
336
|
.with_bindings(
|
338
337
|
uri_method: :get,
|
@@ -355,7 +354,7 @@ module Google
|
|
355
354
|
# A request object representing the call parameters. Required.
|
356
355
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
357
356
|
# Uri, Body, Query string parameters
|
358
|
-
def transcode_insert_request request_pb
|
357
|
+
def self.transcode_insert_request request_pb
|
359
358
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
360
359
|
.with_bindings(
|
361
360
|
uri_method: :post,
|
@@ -378,7 +377,7 @@ module Google
|
|
378
377
|
# A request object representing the call parameters. Required.
|
379
378
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
380
379
|
# Uri, Body, Query string parameters
|
381
|
-
def transcode_list_request request_pb
|
380
|
+
def self.transcode_list_request request_pb
|
382
381
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
383
382
|
.with_bindings(
|
384
383
|
uri_method: :get,
|
@@ -400,7 +399,7 @@ module Google
|
|
400
399
|
# A request object representing the call parameters. Required.
|
401
400
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
402
401
|
# Uri, Body, Query string parameters
|
403
|
-
def transcode_patch_request request_pb
|
402
|
+
def self.transcode_patch_request request_pb
|
404
403
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
405
404
|
.with_bindings(
|
406
405
|
uri_method: :patch,
|
@@ -424,7 +423,7 @@ module Google
|
|
424
423
|
# A request object representing the call parameters. Required.
|
425
424
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
426
425
|
# Uri, Body, Query string parameters
|
427
|
-
def transcode_update_request request_pb
|
426
|
+
def self.transcode_update_request request_pb
|
428
427
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
429
428
|
.with_bindings(
|
430
429
|
uri_method: :put,
|
@@ -448,7 +447,7 @@ module Google
|
|
448
447
|
# A request object representing the call parameters. Required.
|
449
448
|
# @return [Array(String, [String, nil], Hash{String => String})]
|
450
449
|
# Uri, Body, Query string parameters
|
451
|
-
def transcode_validate_request request_pb
|
450
|
+
def self.transcode_validate_request request_pb
|
452
451
|
transcoder = Gapic::Rest::GrpcTranscoder.new
|
453
452
|
.with_bindings(
|
454
453
|
uri_method: :post,
|
@@ -16,12 +16,27 @@
|
|
16
16
|
|
17
17
|
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
18
|
|
19
|
+
require "gapic/rest"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/cloud/compute/v1/version"
|
24
|
+
|
25
|
+
require "google/cloud/compute/v1/region_url_maps/credentials"
|
19
26
|
require "google/cloud/compute/v1/region_url_maps/rest/client"
|
20
27
|
|
21
28
|
module Google
|
22
29
|
module Cloud
|
23
30
|
module Compute
|
24
31
|
module V1
|
32
|
+
##
|
33
|
+
# The RegionUrlMaps API.
|
34
|
+
#
|
35
|
+
# To load this service and instantiate a REST client:
|
36
|
+
#
|
37
|
+
# require "google/cloud/compute/v1/region_url_maps/rest"
|
38
|
+
# client = ::Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client.new
|
39
|
+
#
|
25
40
|
module RegionUrlMaps
|
26
41
|
# Client for the REST transport
|
27
42
|
module Rest
|
@@ -31,3 +46,6 @@ module Google
|
|
31
46
|
end
|
32
47
|
end
|
33
48
|
end
|
49
|
+
|
50
|
+
helper_path = ::File.join __dir__, "rest", "helpers.rb"
|
51
|
+
require "google/cloud/compute/v1/region_url_maps/rest/helpers" if ::File.file? helper_path
|
@@ -31,9 +31,9 @@ module Google
|
|
31
31
|
##
|
32
32
|
# The RegionUrlMaps API.
|
33
33
|
#
|
34
|
-
#
|
34
|
+
# @example Load this service and instantiate a REST client
|
35
35
|
#
|
36
|
-
# require "google/cloud/compute/v1/region_url_maps"
|
36
|
+
# require "google/cloud/compute/v1/region_url_maps/rest"
|
37
37
|
# client = ::Google::Cloud::Compute::V1::RegionUrlMaps::Rest::Client.new
|
38
38
|
#
|
39
39
|
module RegionUrlMaps
|