google-cloud-compute-v1 0.2.0 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.yardopts +1 -1
- data/AUTHENTICATION.md +12 -12
- data/README.md +4 -30
- data/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +123 -66
- data/lib/google/cloud/compute/v1/accelerator_types/rest/service_stub.rb +188 -0
- data/lib/google/cloud/compute/v1/accelerator_types/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/addresses/rest/client.rb +166 -96
- data/lib/google/cloud/compute/v1/addresses/rest/service_stub.rb +279 -0
- data/lib/google/cloud/compute/v1/addresses/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +210 -128
- data/lib/google/cloud/compute/v1/autoscalers/rest/service_stub.rb +373 -0
- data/lib/google/cloud/compute/v1/autoscalers/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +228 -143
- data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +413 -0
- data/lib/google/cloud/compute/v1/backend_buckets/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +294 -187
- data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +553 -0
- data/lib/google/cloud/compute/v1/backend_services/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/compute_pb.rb +816 -135
- data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +123 -66
- data/lib/google/cloud/compute/v1/disk_types/rest/service_stub.rb +188 -0
- data/lib/google/cloud/compute/v1/disk_types/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +334 -213
- data/lib/google/cloud/compute/v1/disks/rest/service_stub.rb +644 -0
- data/lib/google/cloud/compute/v1/disks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +180 -107
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/service_stub.rb +317 -0
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +463 -280
- data/lib/google/cloud/compute/v1/firewall_policies/rest/service_stub.rb +869 -0
- data/lib/google/cloud/compute/v1/firewall_policies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +185 -113
- data/lib/google/cloud/compute/v1/firewalls/rest/service_stub.rb +321 -0
- data/lib/google/cloud/compute/v1/firewalls/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +292 -127
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/service_stub.rb +417 -0
- data/lib/google/cloud/compute/v1/forwarding_rules/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +141 -81
- data/lib/google/cloud/compute/v1/global_addresses/rest/service_stub.rb +229 -0
- data/lib/google/cloud/compute/v1/global_addresses/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +259 -112
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/service_stub.rb +365 -0
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +207 -128
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/service_stub.rb +370 -0
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +159 -88
- data/lib/google/cloud/compute/v1/global_operations/rest/service_stub.rb +274 -0
- data/lib/google/cloud/compute/v1/global_operations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +116 -64
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/service_stub.rb +186 -0
- data/lib/google/cloud/compute/v1/global_organization_operations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +170 -97
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/service_stub.rb +275 -0
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +210 -128
- data/lib/google/cloud/compute/v1/health_checks/rest/service_stub.rb +371 -0
- data/lib/google/cloud/compute/v1/health_checks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/images/rest/client.rb +284 -174
- data/lib/google/cloud/compute/v1/images/rest/service_stub.rb +542 -0
- data/lib/google/cloud/compute/v1/images/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +497 -328
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/service_stub.rb +974 -0
- data/lib/google/cloud/compute/v1/instance_group_managers/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +255 -161
- data/lib/google/cloud/compute/v1/instance_groups/rest/service_stub.rb +467 -0
- data/lib/google/cloud/compute/v1/instance_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +198 -117
- data/lib/google/cloud/compute/v1/instance_templates/rest/service_stub.rb +362 -0
- data/lib/google/cloud/compute/v1/instance_templates/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +1079 -609
- data/lib/google/cloud/compute/v1/instances/rest/service_stub.rb +1975 -0
- data/lib/google/cloud/compute/v1/instances/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +188 -112
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/service_stub.rb +326 -0
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +98 -51
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/service_stub.rb +138 -0
- data/lib/google/cloud/compute/v1/interconnect_locations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +184 -108
- data/lib/google/cloud/compute/v1/interconnects/rest/service_stub.rb +318 -0
- data/lib/google/cloud/compute/v1/interconnects/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/license_codes/rest/client.rb +91 -48
- data/lib/google/cloud/compute/v1/license_codes/rest/service_stub.rb +133 -0
- data/lib/google/cloud/compute/v1/license_codes/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +198 -117
- data/lib/google/cloud/compute/v1/licenses/rest/service_stub.rb +362 -0
- data/lib/google/cloud/compute/v1/licenses/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +123 -66
- data/lib/google/cloud/compute/v1/machine_types/rest/service_stub.rb +188 -0
- data/lib/google/cloud/compute/v1/machine_types/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +251 -157
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/service_stub.rb +465 -0
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +349 -173
- data/lib/google/cloud/compute/v1/networks/rest/service_stub.rb +553 -0
- data/lib/google/cloud/compute/v1/networks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +333 -211
- data/lib/google/cloud/compute/v1/node_groups/rest/service_stub.rb +646 -0
- data/lib/google/cloud/compute/v1/node_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +223 -132
- data/lib/google/cloud/compute/v1/node_templates/rest/service_stub.rb +412 -0
- data/lib/google/cloud/compute/v1/node_templates/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/node_types/rest/client.rb +123 -66
- data/lib/google/cloud/compute/v1/node_types/rest/service_stub.rb +188 -0
- data/lib/google/cloud/compute/v1/node_types/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +206 -124
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/service_stub.rb +369 -0
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +338 -219
- data/lib/google/cloud/compute/v1/projects/rest/service_stub.rb +643 -0
- data/lib/google/cloud/compute/v1/projects/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +170 -97
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/service_stub.rb +275 -0
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +196 -112
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/service_stub.rb +325 -0
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +185 -113
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/service_stub.rb +323 -0
- data/lib/google/cloud/compute/v1/region_autoscalers/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +203 -125
- data/lib/google/cloud/compute/v1/region_backend_services/rest/service_stub.rb +365 -0
- data/lib/google/cloud/compute/v1/region_backend_services/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +145 -82
- data/lib/google/cloud/compute/v1/region_commitments/rest/service_stub.rb +234 -0
- data/lib/google/cloud/compute/v1/region_commitments/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +98 -51
- data/lib/google/cloud/compute/v1/region_disk_types/rest/service_stub.rb +138 -0
- data/lib/google/cloud/compute/v1/region_disk_types/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +309 -198
- data/lib/google/cloud/compute/v1/region_disks/rest/service_stub.rb +593 -0
- data/lib/google/cloud/compute/v1/region_disks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +163 -97
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/service_stub.rb +275 -0
- data/lib/google/cloud/compute/v1/region_health_check_services/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +185 -113
- data/lib/google/cloud/compute/v1/region_health_checks/rest/service_stub.rb +321 -0
- data/lib/google/cloud/compute/v1/region_health_checks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +472 -313
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/service_stub.rb +924 -0
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +143 -84
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/service_stub.rb +234 -0
- data/lib/google/cloud/compute/v1/region_instance_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +75 -40
- data/lib/google/cloud/compute/v1/region_instances/rest/service_stub.rb +92 -0
- data/lib/google/cloud/compute/v1/region_instances/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +141 -81
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/service_stub.rb +229 -0
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +141 -81
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/service_stub.rb +229 -0
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +134 -73
- data/lib/google/cloud/compute/v1/region_operations/rest/service_stub.rb +224 -0
- data/lib/google/cloud/compute/v1/region_operations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +141 -81
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/service_stub.rb +229 -0
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +163 -97
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/service_stub.rb +275 -0
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +185 -113
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/service_stub.rb +321 -0
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +203 -125
- data/lib/google/cloud/compute/v1/region_url_maps/rest/service_stub.rb +365 -0
- data/lib/google/cloud/compute/v1/region_url_maps/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/regions/rest/client.rb +98 -51
- data/lib/google/cloud/compute/v1/regions/rest/service_stub.rb +138 -0
- data/lib/google/cloud/compute/v1/regions/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +245 -148
- data/lib/google/cloud/compute/v1/reservations/rest/service_stub.rb +458 -0
- data/lib/google/cloud/compute/v1/reservations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +223 -132
- data/lib/google/cloud/compute/v1/resource_policies/rest/service_stub.rb +412 -0
- data/lib/google/cloud/compute/v1/resource_policies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +274 -166
- data/lib/google/cloud/compute/v1/routers/rest/service_stub.rb +507 -0
- data/lib/google/cloud/compute/v1/routers/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +141 -81
- data/lib/google/cloud/compute/v1/routes/rest/service_stub.rb +229 -0
- data/lib/google/cloud/compute/v1/routes/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +270 -166
- data/lib/google/cloud/compute/v1/security_policies/rest/service_stub.rb +504 -0
- data/lib/google/cloud/compute/v1/security_policies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +197 -115
- data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +360 -0
- data/lib/google/cloud/compute/v1/snapshots/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +166 -96
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/service_stub.rb +279 -0
- data/lib/google/cloud/compute/v1/ssl_certificates/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +185 -110
- data/lib/google/cloud/compute/v1/ssl_policies/rest/service_stub.rb +324 -0
- data/lib/google/cloud/compute/v1/ssl_policies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +314 -195
- data/lib/google/cloud/compute/v1/subnetworks/rest/service_stub.rb +600 -0
- data/lib/google/cloud/compute/v1/subnetworks/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +163 -97
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/service_stub.rb +275 -0
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +210 -128
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/service_stub.rb +371 -0
- data/lib/google/cloud/compute/v1/target_http_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +334 -159
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/service_stub.rb +509 -0
- data/lib/google/cloud/compute/v1/target_https_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +166 -96
- data/lib/google/cloud/compute/v1/target_instances/rest/service_stub.rb +279 -0
- data/lib/google/cloud/compute/v1/target_instances/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +294 -188
- data/lib/google/cloud/compute/v1/target_pools/rest/service_stub.rb +554 -0
- data/lib/google/cloud/compute/v1/target_pools/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +229 -145
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/service_stub.rb +413 -0
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +185 -113
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/service_stub.rb +321 -0
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +166 -96
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/service_stub.rb +279 -0
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +250 -156
- data/lib/google/cloud/compute/v1/url_maps/rest/service_stub.rb +461 -0
- data/lib/google/cloud/compute/v1/url_maps/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +227 -135
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/service_stub.rb +412 -0
- data/lib/google/cloud/compute/v1/vpn_gateways/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +166 -96
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/service_stub.rb +279 -0
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +134 -73
- data/lib/google/cloud/compute/v1/zone_operations/rest/service_stub.rb +224 -0
- data/lib/google/cloud/compute/v1/zone_operations/rest.rb +0 -2
- data/lib/google/cloud/compute/v1/zones/rest/client.rb +98 -51
- data/lib/google/cloud/compute/v1/zones/rest/service_stub.rb +138 -0
- data/lib/google/cloud/compute/v1/zones/rest.rb +0 -2
- data/lib/google/cloud/compute/v1.rb +5 -0
- data/proto_docs/README.md +1 -1
- data/proto_docs/google/cloud/compute/v1/compute.rb +2526 -640
- metadata +84 -8
@@ -0,0 +1,371 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "google/cloud/compute/v1/compute_pb"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Cloud
|
23
|
+
module Compute
|
24
|
+
module V1
|
25
|
+
module TargetHttpProxies
|
26
|
+
module Rest
|
27
|
+
##
|
28
|
+
# REST service stub for the TargetHttpProxies service.
|
29
|
+
# service stub contains baseline method implementations
|
30
|
+
# including transcoding, making the REST call and deserialing the response
|
31
|
+
#
|
32
|
+
class ServiceStub
|
33
|
+
def initialize endpoint:, credentials:
|
34
|
+
# These require statements are intentionally placed here to initialize
|
35
|
+
# the REST modules only when it's required.
|
36
|
+
require "gapic/rest"
|
37
|
+
|
38
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, credentials: credentials
|
39
|
+
end
|
40
|
+
|
41
|
+
##
|
42
|
+
# Baseline implementation for the aggregated_list REST call
|
43
|
+
#
|
44
|
+
# @param request_pb [::Google::Cloud::Compute::V1::AggregatedListTargetHttpProxiesRequest]
|
45
|
+
# A request object representing the call parameters. Required.
|
46
|
+
# @param options [::Gapic::CallOptions]
|
47
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
48
|
+
#
|
49
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
50
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TargetHttpProxyAggregatedList]
|
51
|
+
# @yieldparam response [::Faraday::Response]
|
52
|
+
#
|
53
|
+
# @return [::Google::Cloud::Compute::V1::TargetHttpProxyAggregatedList]
|
54
|
+
# A result object deserialized from the server's reply
|
55
|
+
def aggregated_list request_pb, options = nil
|
56
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
57
|
+
|
58
|
+
uri, _body, query_string_params = transcode_aggregated_list_request request_pb
|
59
|
+
response = @client_stub.make_get_request(
|
60
|
+
uri: uri,
|
61
|
+
params: query_string_params,
|
62
|
+
options: options
|
63
|
+
)
|
64
|
+
result = ::Google::Cloud::Compute::V1::TargetHttpProxyAggregatedList.decode_json response.body, ignore_unknown_fields: true
|
65
|
+
|
66
|
+
yield result, response if block_given?
|
67
|
+
result
|
68
|
+
end
|
69
|
+
|
70
|
+
##
|
71
|
+
# GRPC transcoding helper method for the aggregated_list REST call
|
72
|
+
#
|
73
|
+
# @param request_pb [::Google::Cloud::Compute::V1::AggregatedListTargetHttpProxiesRequest]
|
74
|
+
# A request object representing the call parameters. Required.
|
75
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
76
|
+
# Uri, Body, Query string parameters
|
77
|
+
def transcode_aggregated_list_request request_pb
|
78
|
+
uri = "/compute/v1/projects/#{request_pb.project}/aggregated/targetHttpProxies"
|
79
|
+
body = nil
|
80
|
+
query_string_params = {}
|
81
|
+
query_string_params["filter"] = request_pb.filter.to_s if request_pb.has_filter?
|
82
|
+
query_string_params["includeAllScopes"] = request_pb.include_all_scopes.to_s if request_pb.has_include_all_scopes?
|
83
|
+
query_string_params["maxResults"] = request_pb.max_results.to_s if request_pb.has_max_results?
|
84
|
+
query_string_params["orderBy"] = request_pb.order_by.to_s if request_pb.has_order_by?
|
85
|
+
query_string_params["pageToken"] = request_pb.page_token.to_s if request_pb.has_page_token?
|
86
|
+
query_string_params["returnPartialSuccess"] = request_pb.return_partial_success.to_s if request_pb.has_return_partial_success?
|
87
|
+
|
88
|
+
[uri, body, query_string_params]
|
89
|
+
end
|
90
|
+
|
91
|
+
##
|
92
|
+
# Baseline implementation for the delete REST call
|
93
|
+
#
|
94
|
+
# @param request_pb [::Google::Cloud::Compute::V1::DeleteTargetHttpProxyRequest]
|
95
|
+
# A request object representing the call parameters. Required.
|
96
|
+
# @param options [::Gapic::CallOptions]
|
97
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
98
|
+
#
|
99
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
100
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Operation]
|
101
|
+
# @yieldparam response [::Faraday::Response]
|
102
|
+
#
|
103
|
+
# @return [::Google::Cloud::Compute::V1::Operation]
|
104
|
+
# A result object deserialized from the server's reply
|
105
|
+
def delete request_pb, options = nil
|
106
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
107
|
+
|
108
|
+
uri, _body, query_string_params = transcode_delete_request request_pb
|
109
|
+
response = @client_stub.make_delete_request(
|
110
|
+
uri: uri,
|
111
|
+
params: query_string_params,
|
112
|
+
options: options
|
113
|
+
)
|
114
|
+
result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
115
|
+
|
116
|
+
yield result, response if block_given?
|
117
|
+
result
|
118
|
+
end
|
119
|
+
|
120
|
+
##
|
121
|
+
# GRPC transcoding helper method for the delete REST call
|
122
|
+
#
|
123
|
+
# @param request_pb [::Google::Cloud::Compute::V1::DeleteTargetHttpProxyRequest]
|
124
|
+
# A request object representing the call parameters. Required.
|
125
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
126
|
+
# Uri, Body, Query string parameters
|
127
|
+
def transcode_delete_request request_pb
|
128
|
+
uri = "/compute/v1/projects/#{request_pb.project}/global/targetHttpProxies/#{request_pb.target_http_proxy}"
|
129
|
+
body = nil
|
130
|
+
query_string_params = {}
|
131
|
+
query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id?
|
132
|
+
|
133
|
+
[uri, body, query_string_params]
|
134
|
+
end
|
135
|
+
|
136
|
+
##
|
137
|
+
# Baseline implementation for the get REST call
|
138
|
+
#
|
139
|
+
# @param request_pb [::Google::Cloud::Compute::V1::GetTargetHttpProxyRequest]
|
140
|
+
# A request object representing the call parameters. Required.
|
141
|
+
# @param options [::Gapic::CallOptions]
|
142
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
143
|
+
#
|
144
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
145
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TargetHttpProxy]
|
146
|
+
# @yieldparam response [::Faraday::Response]
|
147
|
+
#
|
148
|
+
# @return [::Google::Cloud::Compute::V1::TargetHttpProxy]
|
149
|
+
# A result object deserialized from the server's reply
|
150
|
+
def get request_pb, options = nil
|
151
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
152
|
+
|
153
|
+
uri, _body, _query_string_params = transcode_get_request request_pb
|
154
|
+
response = @client_stub.make_get_request(
|
155
|
+
uri: uri,
|
156
|
+
options: options
|
157
|
+
)
|
158
|
+
result = ::Google::Cloud::Compute::V1::TargetHttpProxy.decode_json response.body, ignore_unknown_fields: true
|
159
|
+
|
160
|
+
yield result, response if block_given?
|
161
|
+
result
|
162
|
+
end
|
163
|
+
|
164
|
+
##
|
165
|
+
# GRPC transcoding helper method for the get REST call
|
166
|
+
#
|
167
|
+
# @param request_pb [::Google::Cloud::Compute::V1::GetTargetHttpProxyRequest]
|
168
|
+
# A request object representing the call parameters. Required.
|
169
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
170
|
+
# Uri, Body, Query string parameters
|
171
|
+
def transcode_get_request request_pb
|
172
|
+
uri = "/compute/v1/projects/#{request_pb.project}/global/targetHttpProxies/#{request_pb.target_http_proxy}"
|
173
|
+
body = nil
|
174
|
+
query_string_params = {}
|
175
|
+
|
176
|
+
[uri, body, query_string_params]
|
177
|
+
end
|
178
|
+
|
179
|
+
##
|
180
|
+
# Baseline implementation for the insert REST call
|
181
|
+
#
|
182
|
+
# @param request_pb [::Google::Cloud::Compute::V1::InsertTargetHttpProxyRequest]
|
183
|
+
# A request object representing the call parameters. Required.
|
184
|
+
# @param options [::Gapic::CallOptions]
|
185
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
186
|
+
#
|
187
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
188
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Operation]
|
189
|
+
# @yieldparam response [::Faraday::Response]
|
190
|
+
#
|
191
|
+
# @return [::Google::Cloud::Compute::V1::Operation]
|
192
|
+
# A result object deserialized from the server's reply
|
193
|
+
def insert request_pb, options = nil
|
194
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
195
|
+
|
196
|
+
uri, body, query_string_params = transcode_insert_request request_pb
|
197
|
+
response = @client_stub.make_post_request(
|
198
|
+
uri: uri,
|
199
|
+
body: body,
|
200
|
+
params: query_string_params,
|
201
|
+
options: options
|
202
|
+
)
|
203
|
+
result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
204
|
+
|
205
|
+
yield result, response if block_given?
|
206
|
+
result
|
207
|
+
end
|
208
|
+
|
209
|
+
##
|
210
|
+
# GRPC transcoding helper method for the insert REST call
|
211
|
+
#
|
212
|
+
# @param request_pb [::Google::Cloud::Compute::V1::InsertTargetHttpProxyRequest]
|
213
|
+
# A request object representing the call parameters. Required.
|
214
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
215
|
+
# Uri, Body, Query string parameters
|
216
|
+
def transcode_insert_request request_pb
|
217
|
+
uri = "/compute/v1/projects/#{request_pb.project}/global/targetHttpProxies"
|
218
|
+
body = request_pb.target_http_proxy_resource.to_json
|
219
|
+
query_string_params = {}
|
220
|
+
query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id?
|
221
|
+
|
222
|
+
[uri, body, query_string_params]
|
223
|
+
end
|
224
|
+
|
225
|
+
##
|
226
|
+
# Baseline implementation for the list REST call
|
227
|
+
#
|
228
|
+
# @param request_pb [::Google::Cloud::Compute::V1::ListTargetHttpProxiesRequest]
|
229
|
+
# A request object representing the call parameters. Required.
|
230
|
+
# @param options [::Gapic::CallOptions]
|
231
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
232
|
+
#
|
233
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
234
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::TargetHttpProxyList]
|
235
|
+
# @yieldparam response [::Faraday::Response]
|
236
|
+
#
|
237
|
+
# @return [::Google::Cloud::Compute::V1::TargetHttpProxyList]
|
238
|
+
# A result object deserialized from the server's reply
|
239
|
+
def list request_pb, options = nil
|
240
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
241
|
+
|
242
|
+
uri, _body, query_string_params = transcode_list_request request_pb
|
243
|
+
response = @client_stub.make_get_request(
|
244
|
+
uri: uri,
|
245
|
+
params: query_string_params,
|
246
|
+
options: options
|
247
|
+
)
|
248
|
+
result = ::Google::Cloud::Compute::V1::TargetHttpProxyList.decode_json response.body, ignore_unknown_fields: true
|
249
|
+
|
250
|
+
yield result, response if block_given?
|
251
|
+
result
|
252
|
+
end
|
253
|
+
|
254
|
+
##
|
255
|
+
# GRPC transcoding helper method for the list REST call
|
256
|
+
#
|
257
|
+
# @param request_pb [::Google::Cloud::Compute::V1::ListTargetHttpProxiesRequest]
|
258
|
+
# A request object representing the call parameters. Required.
|
259
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
260
|
+
# Uri, Body, Query string parameters
|
261
|
+
def transcode_list_request request_pb
|
262
|
+
uri = "/compute/v1/projects/#{request_pb.project}/global/targetHttpProxies"
|
263
|
+
body = nil
|
264
|
+
query_string_params = {}
|
265
|
+
query_string_params["filter"] = request_pb.filter.to_s if request_pb.has_filter?
|
266
|
+
query_string_params["maxResults"] = request_pb.max_results.to_s if request_pb.has_max_results?
|
267
|
+
query_string_params["orderBy"] = request_pb.order_by.to_s if request_pb.has_order_by?
|
268
|
+
query_string_params["pageToken"] = request_pb.page_token.to_s if request_pb.has_page_token?
|
269
|
+
query_string_params["returnPartialSuccess"] = request_pb.return_partial_success.to_s if request_pb.has_return_partial_success?
|
270
|
+
|
271
|
+
[uri, body, query_string_params]
|
272
|
+
end
|
273
|
+
|
274
|
+
##
|
275
|
+
# Baseline implementation for the patch REST call
|
276
|
+
#
|
277
|
+
# @param request_pb [::Google::Cloud::Compute::V1::PatchTargetHttpProxyRequest]
|
278
|
+
# A request object representing the call parameters. Required.
|
279
|
+
# @param options [::Gapic::CallOptions]
|
280
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
281
|
+
#
|
282
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
283
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Operation]
|
284
|
+
# @yieldparam response [::Faraday::Response]
|
285
|
+
#
|
286
|
+
# @return [::Google::Cloud::Compute::V1::Operation]
|
287
|
+
# A result object deserialized from the server's reply
|
288
|
+
def patch request_pb, options = nil
|
289
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
290
|
+
|
291
|
+
uri, body, query_string_params = transcode_patch_request request_pb
|
292
|
+
response = @client_stub.make_patch_request(
|
293
|
+
uri: uri,
|
294
|
+
body: body,
|
295
|
+
params: query_string_params,
|
296
|
+
options: options
|
297
|
+
)
|
298
|
+
result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
299
|
+
|
300
|
+
yield result, response if block_given?
|
301
|
+
result
|
302
|
+
end
|
303
|
+
|
304
|
+
##
|
305
|
+
# GRPC transcoding helper method for the patch REST call
|
306
|
+
#
|
307
|
+
# @param request_pb [::Google::Cloud::Compute::V1::PatchTargetHttpProxyRequest]
|
308
|
+
# A request object representing the call parameters. Required.
|
309
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
310
|
+
# Uri, Body, Query string parameters
|
311
|
+
def transcode_patch_request request_pb
|
312
|
+
uri = "/compute/v1/projects/#{request_pb.project}/global/targetHttpProxies/#{request_pb.target_http_proxy}"
|
313
|
+
body = request_pb.target_http_proxy_resource.to_json
|
314
|
+
query_string_params = {}
|
315
|
+
query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id?
|
316
|
+
|
317
|
+
[uri, body, query_string_params]
|
318
|
+
end
|
319
|
+
|
320
|
+
##
|
321
|
+
# Baseline implementation for the set_url_map REST call
|
322
|
+
#
|
323
|
+
# @param request_pb [::Google::Cloud::Compute::V1::SetUrlMapTargetHttpProxyRequest]
|
324
|
+
# A request object representing the call parameters. Required.
|
325
|
+
# @param options [::Gapic::CallOptions]
|
326
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
327
|
+
#
|
328
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
329
|
+
# @yieldparam result [::Google::Cloud::Compute::V1::Operation]
|
330
|
+
# @yieldparam response [::Faraday::Response]
|
331
|
+
#
|
332
|
+
# @return [::Google::Cloud::Compute::V1::Operation]
|
333
|
+
# A result object deserialized from the server's reply
|
334
|
+
def set_url_map request_pb, options = nil
|
335
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
336
|
+
|
337
|
+
uri, body, query_string_params = transcode_set_url_map_request request_pb
|
338
|
+
response = @client_stub.make_post_request(
|
339
|
+
uri: uri,
|
340
|
+
body: body,
|
341
|
+
params: query_string_params,
|
342
|
+
options: options
|
343
|
+
)
|
344
|
+
result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
345
|
+
|
346
|
+
yield result, response if block_given?
|
347
|
+
result
|
348
|
+
end
|
349
|
+
|
350
|
+
##
|
351
|
+
# GRPC transcoding helper method for the set_url_map REST call
|
352
|
+
#
|
353
|
+
# @param request_pb [::Google::Cloud::Compute::V1::SetUrlMapTargetHttpProxyRequest]
|
354
|
+
# A request object representing the call parameters. Required.
|
355
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
356
|
+
# Uri, Body, Query string parameters
|
357
|
+
def transcode_set_url_map_request request_pb
|
358
|
+
uri = "/compute/v1/projects/#{request_pb.project}/targetHttpProxies/#{request_pb.target_http_proxy}/setUrlMap"
|
359
|
+
body = request_pb.url_map_reference_resource.to_json
|
360
|
+
query_string_params = {}
|
361
|
+
query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id?
|
362
|
+
|
363
|
+
[uri, body, query_string_params]
|
364
|
+
end
|
365
|
+
end
|
366
|
+
end
|
367
|
+
end
|
368
|
+
end
|
369
|
+
end
|
370
|
+
end
|
371
|
+
end
|
@@ -18,6 +18,7 @@
|
|
18
18
|
|
19
19
|
require "google/cloud/errors"
|
20
20
|
require "google/cloud/compute/v1/compute_pb"
|
21
|
+
require "google/cloud/compute/v1/target_https_proxies/rest/service_stub"
|
21
22
|
|
22
23
|
module Google
|
23
24
|
module Cloud
|
@@ -31,8 +32,6 @@ module Google
|
|
31
32
|
# The TargetHttpsProxies API.
|
32
33
|
#
|
33
34
|
class Client
|
34
|
-
include GrpcTranscoding
|
35
|
-
|
36
35
|
# @private
|
37
36
|
attr_reader :target_https_proxies_stub
|
38
37
|
|
@@ -42,13 +41,12 @@ module Google
|
|
42
41
|
# See {::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client::Configuration}
|
43
42
|
# for a description of the configuration fields.
|
44
43
|
#
|
45
|
-
#
|
46
|
-
#
|
47
|
-
# To modify the configuration for all TargetHttpsProxies clients:
|
44
|
+
# @example
|
48
45
|
#
|
49
|
-
#
|
50
|
-
#
|
51
|
-
#
|
46
|
+
# # Modify the configuration for all TargetHttpsProxies clients
|
47
|
+
# ::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client.configure do |config|
|
48
|
+
# config.timeout = 10.0
|
49
|
+
# end
|
52
50
|
#
|
53
51
|
# @yield [config] Configure the Client client.
|
54
52
|
# @yieldparam config [Client::Configuration]
|
@@ -66,6 +64,35 @@ module Google
|
|
66
64
|
end
|
67
65
|
default_config = Client::Configuration.new parent_config
|
68
66
|
|
67
|
+
default_config.rpcs.aggregated_list.timeout = 600.0
|
68
|
+
default_config.rpcs.aggregated_list.retry_policy = {
|
69
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
70
|
+
}
|
71
|
+
|
72
|
+
default_config.rpcs.delete.timeout = 600.0
|
73
|
+
|
74
|
+
default_config.rpcs.get.timeout = 600.0
|
75
|
+
default_config.rpcs.get.retry_policy = {
|
76
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
77
|
+
}
|
78
|
+
|
79
|
+
default_config.rpcs.insert.timeout = 600.0
|
80
|
+
|
81
|
+
default_config.rpcs.list.timeout = 600.0
|
82
|
+
default_config.rpcs.list.retry_policy = {
|
83
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
|
84
|
+
}
|
85
|
+
|
86
|
+
default_config.rpcs.patch.timeout = 600.0
|
87
|
+
|
88
|
+
default_config.rpcs.set_quic_override.timeout = 600.0
|
89
|
+
|
90
|
+
default_config.rpcs.set_ssl_certificates.timeout = 600.0
|
91
|
+
|
92
|
+
default_config.rpcs.set_ssl_policy.timeout = 600.0
|
93
|
+
|
94
|
+
default_config.rpcs.set_url_map.timeout = 600.0
|
95
|
+
|
69
96
|
default_config
|
70
97
|
end
|
71
98
|
yield @configure if block_given?
|
@@ -95,28 +122,20 @@ module Google
|
|
95
122
|
##
|
96
123
|
# Create a new TargetHttpsProxies REST client object.
|
97
124
|
#
|
98
|
-
#
|
125
|
+
# @example
|
99
126
|
#
|
100
|
-
#
|
101
|
-
#
|
127
|
+
# # Create a client using the default configuration
|
128
|
+
# client = ::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client.new
|
102
129
|
#
|
103
|
-
#
|
104
|
-
#
|
105
|
-
#
|
106
|
-
#
|
107
|
-
#
|
108
|
-
# client = ::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client.new do |config|
|
109
|
-
# config.timeout = 10.0
|
110
|
-
# end
|
130
|
+
# # Create a client using a custom configuration
|
131
|
+
# client = ::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::Client.new do |config|
|
132
|
+
# config.timeout = 10.0
|
133
|
+
# end
|
111
134
|
#
|
112
135
|
# @yield [config] Configure the TargetHttpsProxies client.
|
113
136
|
# @yieldparam config [Client::Configuration]
|
114
137
|
#
|
115
138
|
def initialize
|
116
|
-
# These require statements are intentionally placed here to initialize
|
117
|
-
# the REST modules only when it's required.
|
118
|
-
require "gapic/rest"
|
119
|
-
|
120
139
|
# Create the configuration object
|
121
140
|
@config = Configuration.new Client.configure
|
122
141
|
|
@@ -126,11 +145,11 @@ module Google
|
|
126
145
|
# Create credentials
|
127
146
|
credentials = @config.credentials
|
128
147
|
credentials ||= Credentials.default scope: @config.scope
|
129
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
148
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
130
149
|
credentials = Credentials.new credentials, scope: @config.scope
|
131
150
|
end
|
132
151
|
|
133
|
-
@
|
152
|
+
@target_https_proxies_stub = ::Google::Cloud::Compute::V1::TargetHttpsProxies::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
134
153
|
end
|
135
154
|
|
136
155
|
# Service calls
|
@@ -178,12 +197,12 @@ module Google
|
|
178
197
|
# @param project [::String]
|
179
198
|
# Name of the project scoping this request.
|
180
199
|
# @param return_partial_success [::Boolean]
|
181
|
-
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false
|
182
|
-
# @yield [result,
|
183
|
-
# @yieldparam result [::Google::Cloud::Compute::V1::
|
200
|
+
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
201
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
202
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::String, ::Google::Cloud::Compute::V1::TargetHttpsProxiesScopedList>]
|
184
203
|
# @yieldparam response [::Faraday::Response]
|
185
204
|
#
|
186
|
-
# @return [::Google::Cloud::Compute::V1::
|
205
|
+
# @return [::Gapic::Rest::PagedEnumerable<::String, ::Google::Cloud::Compute::V1::TargetHttpsProxiesScopedList>]
|
187
206
|
#
|
188
207
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
189
208
|
def aggregated_list request, options = nil
|
@@ -195,7 +214,7 @@ module Google
|
|
195
214
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
196
215
|
|
197
216
|
# Customize the options with defaults
|
198
|
-
call_metadata =
|
217
|
+
call_metadata = @config.rpcs.aggregated_list.metadata.to_h
|
199
218
|
|
200
219
|
# Set x-goog-api-client header
|
201
220
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -203,19 +222,17 @@ module Google
|
|
203
222
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
204
223
|
transports_version_send: [:rest]
|
205
224
|
|
206
|
-
options.apply_defaults timeout: @config.timeout,
|
225
|
+
options.apply_defaults timeout: @config.rpcs.aggregated_list.timeout,
|
207
226
|
metadata: call_metadata
|
208
227
|
|
209
|
-
|
210
|
-
|
211
|
-
uri: uri,
|
212
|
-
params: query_string_params,
|
213
|
-
options: options
|
214
|
-
)
|
215
|
-
result = ::Google::Cloud::Compute::V1::TargetHttpsProxyAggregatedList.decode_json response.body, ignore_unknown_fields: true
|
228
|
+
options.apply_defaults timeout: @config.timeout,
|
229
|
+
metadata: @config.metadata
|
216
230
|
|
217
|
-
|
218
|
-
|
231
|
+
@target_https_proxies_stub.aggregated_list request, options do |result, response|
|
232
|
+
result = ::Gapic::Rest::PagedEnumerable.new @target_https_proxies_stub, :aggregated_list, "items", request, result, options
|
233
|
+
yield result, response if block_given?
|
234
|
+
return result
|
235
|
+
end
|
219
236
|
rescue ::Faraday::Error => e
|
220
237
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
221
238
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -251,11 +268,11 @@ module Google
|
|
251
268
|
# The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
252
269
|
# @param target_https_proxy [::String]
|
253
270
|
# Name of the TargetHttpsProxy resource to delete.
|
254
|
-
# @yield [result,
|
255
|
-
# @yieldparam result [::
|
271
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
272
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
256
273
|
# @yieldparam response [::Faraday::Response]
|
257
274
|
#
|
258
|
-
# @return [::
|
275
|
+
# @return [::Gapic::Rest::BaseOperation]
|
259
276
|
#
|
260
277
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
261
278
|
def delete request, options = nil
|
@@ -267,7 +284,7 @@ module Google
|
|
267
284
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
268
285
|
|
269
286
|
# Customize the options with defaults
|
270
|
-
call_metadata =
|
287
|
+
call_metadata = @config.rpcs.delete.metadata.to_h
|
271
288
|
|
272
289
|
# Set x-goog-api-client header
|
273
290
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -275,19 +292,17 @@ module Google
|
|
275
292
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
276
293
|
transports_version_send: [:rest]
|
277
294
|
|
278
|
-
options.apply_defaults timeout: @config.timeout,
|
295
|
+
options.apply_defaults timeout: @config.rpcs.delete.timeout,
|
279
296
|
metadata: call_metadata
|
280
297
|
|
281
|
-
|
282
|
-
|
283
|
-
uri: uri,
|
284
|
-
params: query_string_params,
|
285
|
-
options: options
|
286
|
-
)
|
287
|
-
result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
298
|
+
options.apply_defaults timeout: @config.timeout,
|
299
|
+
metadata: @config.metadata
|
288
300
|
|
289
|
-
|
290
|
-
|
301
|
+
@target_https_proxies_stub.delete request, options do |result, response|
|
302
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
303
|
+
yield result, response if block_given?
|
304
|
+
return result
|
305
|
+
end
|
291
306
|
rescue ::Faraday::Error => e
|
292
307
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
293
308
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -317,7 +332,7 @@ module Google
|
|
317
332
|
# Project ID for this request.
|
318
333
|
# @param target_https_proxy [::String]
|
319
334
|
# Name of the TargetHttpsProxy resource to return.
|
320
|
-
# @yield [result,
|
335
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
321
336
|
# @yieldparam result [::Google::Cloud::Compute::V1::TargetHttpsProxy]
|
322
337
|
# @yieldparam response [::Faraday::Response]
|
323
338
|
#
|
@@ -333,7 +348,7 @@ module Google
|
|
333
348
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
334
349
|
|
335
350
|
# Customize the options with defaults
|
336
|
-
call_metadata =
|
351
|
+
call_metadata = @config.rpcs.get.metadata.to_h
|
337
352
|
|
338
353
|
# Set x-goog-api-client header
|
339
354
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -341,18 +356,16 @@ module Google
|
|
341
356
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
342
357
|
transports_version_send: [:rest]
|
343
358
|
|
344
|
-
options.apply_defaults timeout: @config.timeout,
|
359
|
+
options.apply_defaults timeout: @config.rpcs.get.timeout,
|
345
360
|
metadata: call_metadata
|
346
361
|
|
347
|
-
|
348
|
-
|
349
|
-
uri: uri,
|
350
|
-
options: options
|
351
|
-
)
|
352
|
-
result = ::Google::Cloud::Compute::V1::TargetHttpsProxy.decode_json response.body, ignore_unknown_fields: true
|
362
|
+
options.apply_defaults timeout: @config.timeout,
|
363
|
+
metadata: @config.metadata
|
353
364
|
|
354
|
-
|
355
|
-
|
365
|
+
@target_https_proxies_stub.get request, options do |result, response|
|
366
|
+
yield result, response if block_given?
|
367
|
+
return result
|
368
|
+
end
|
356
369
|
rescue ::Faraday::Error => e
|
357
370
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
358
371
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -388,11 +401,11 @@ module Google
|
|
388
401
|
# The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
389
402
|
# @param target_https_proxy_resource [::Google::Cloud::Compute::V1::TargetHttpsProxy, ::Hash]
|
390
403
|
# The body resource for this request
|
391
|
-
# @yield [result,
|
392
|
-
# @yieldparam result [::
|
404
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
405
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
393
406
|
# @yieldparam response [::Faraday::Response]
|
394
407
|
#
|
395
|
-
# @return [::
|
408
|
+
# @return [::Gapic::Rest::BaseOperation]
|
396
409
|
#
|
397
410
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
398
411
|
def insert request, options = nil
|
@@ -404,7 +417,7 @@ module Google
|
|
404
417
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
405
418
|
|
406
419
|
# Customize the options with defaults
|
407
|
-
call_metadata =
|
420
|
+
call_metadata = @config.rpcs.insert.metadata.to_h
|
408
421
|
|
409
422
|
# Set x-goog-api-client header
|
410
423
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -412,20 +425,17 @@ module Google
|
|
412
425
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
413
426
|
transports_version_send: [:rest]
|
414
427
|
|
415
|
-
options.apply_defaults timeout: @config.timeout,
|
428
|
+
options.apply_defaults timeout: @config.rpcs.insert.timeout,
|
416
429
|
metadata: call_metadata
|
417
430
|
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
yield result, response if block_given?
|
428
|
-
result
|
431
|
+
options.apply_defaults timeout: @config.timeout,
|
432
|
+
metadata: @config.metadata
|
433
|
+
|
434
|
+
@target_https_proxies_stub.insert request, options do |result, response|
|
435
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
436
|
+
yield result, response if block_given?
|
437
|
+
return result
|
438
|
+
end
|
429
439
|
rescue ::Faraday::Error => e
|
430
440
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
431
441
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -472,12 +482,12 @@ module Google
|
|
472
482
|
# @param project [::String]
|
473
483
|
# Project ID for this request.
|
474
484
|
# @param return_partial_success [::Boolean]
|
475
|
-
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false
|
476
|
-
# @yield [result,
|
477
|
-
# @yieldparam result [::Google::Cloud::Compute::V1::
|
485
|
+
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
486
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
487
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::TargetHttpsProxy>]
|
478
488
|
# @yieldparam response [::Faraday::Response]
|
479
489
|
#
|
480
|
-
# @return [::Google::Cloud::Compute::V1::
|
490
|
+
# @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::TargetHttpsProxy>]
|
481
491
|
#
|
482
492
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
483
493
|
def list request, options = nil
|
@@ -489,7 +499,7 @@ module Google
|
|
489
499
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
490
500
|
|
491
501
|
# Customize the options with defaults
|
492
|
-
call_metadata =
|
502
|
+
call_metadata = @config.rpcs.list.metadata.to_h
|
493
503
|
|
494
504
|
# Set x-goog-api-client header
|
495
505
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -497,19 +507,89 @@ module Google
|
|
497
507
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
498
508
|
transports_version_send: [:rest]
|
499
509
|
|
510
|
+
options.apply_defaults timeout: @config.rpcs.list.timeout,
|
511
|
+
metadata: call_metadata
|
512
|
+
|
500
513
|
options.apply_defaults timeout: @config.timeout,
|
514
|
+
metadata: @config.metadata
|
515
|
+
|
516
|
+
@target_https_proxies_stub.list request, options do |result, response|
|
517
|
+
result = ::Gapic::Rest::PagedEnumerable.new @target_https_proxies_stub, :list, "items", request, result, options
|
518
|
+
yield result, response if block_given?
|
519
|
+
return result
|
520
|
+
end
|
521
|
+
rescue ::Faraday::Error => e
|
522
|
+
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
523
|
+
raise ::Google::Cloud::Error.from_error(gapic_error)
|
524
|
+
end
|
525
|
+
|
526
|
+
##
|
527
|
+
# Patches the specified TargetHttpsProxy resource with the data included in the request. This method supports PATCH semantics and uses JSON merge patch format and processing rules. (== suppress_warning http-rest-shadowed ==)
|
528
|
+
#
|
529
|
+
# @overload patch(request, options = nil)
|
530
|
+
# Pass arguments to `patch` via a request object, either of type
|
531
|
+
# {::Google::Cloud::Compute::V1::PatchTargetHttpsProxyRequest} or an equivalent Hash.
|
532
|
+
#
|
533
|
+
# @param request [::Google::Cloud::Compute::V1::PatchTargetHttpsProxyRequest, ::Hash]
|
534
|
+
# A request object representing the call parameters. Required. To specify no
|
535
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
536
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
537
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
538
|
+
# Note: currently retry functionality is not implemented. While it is possible
|
539
|
+
# to set it using ::Gapic::CallOptions, it will not be applied
|
540
|
+
#
|
541
|
+
# @overload patch(project: nil, request_id: nil, target_https_proxy: nil, target_https_proxy_resource: nil)
|
542
|
+
# Pass arguments to `patch` via keyword arguments. Note that at
|
543
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
544
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
545
|
+
#
|
546
|
+
# @param project [::String]
|
547
|
+
# Project ID for this request.
|
548
|
+
# @param request_id [::String]
|
549
|
+
# An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed.
|
550
|
+
#
|
551
|
+
# For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.
|
552
|
+
#
|
553
|
+
# The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
554
|
+
# @param target_https_proxy [::String]
|
555
|
+
# Name of the TargetHttpsProxy resource to patch.
|
556
|
+
# @param target_https_proxy_resource [::Google::Cloud::Compute::V1::TargetHttpsProxy, ::Hash]
|
557
|
+
# The body resource for this request
|
558
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
559
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
560
|
+
# @yieldparam response [::Faraday::Response]
|
561
|
+
#
|
562
|
+
# @return [::Gapic::Rest::BaseOperation]
|
563
|
+
#
|
564
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
565
|
+
def patch request, options = nil
|
566
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
567
|
+
|
568
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::PatchTargetHttpsProxyRequest
|
569
|
+
|
570
|
+
# Converts hash and nil to an options object
|
571
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
572
|
+
|
573
|
+
# Customize the options with defaults
|
574
|
+
call_metadata = @config.rpcs.patch.metadata.to_h
|
575
|
+
|
576
|
+
# Set x-goog-api-client header
|
577
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
578
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
579
|
+
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
580
|
+
transports_version_send: [:rest]
|
581
|
+
|
582
|
+
options.apply_defaults timeout: @config.rpcs.patch.timeout,
|
501
583
|
metadata: call_metadata
|
502
584
|
|
503
|
-
|
504
|
-
|
505
|
-
uri: uri,
|
506
|
-
params: query_string_params,
|
507
|
-
options: options
|
508
|
-
)
|
509
|
-
result = ::Google::Cloud::Compute::V1::TargetHttpsProxyList.decode_json response.body, ignore_unknown_fields: true
|
585
|
+
options.apply_defaults timeout: @config.timeout,
|
586
|
+
metadata: @config.metadata
|
510
587
|
|
511
|
-
|
512
|
-
|
588
|
+
@target_https_proxies_stub.patch request, options do |result, response|
|
589
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
590
|
+
yield result, response if block_given?
|
591
|
+
return result
|
592
|
+
end
|
513
593
|
rescue ::Faraday::Error => e
|
514
594
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
515
595
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -547,11 +627,11 @@ module Google
|
|
547
627
|
# The body resource for this request
|
548
628
|
# @param target_https_proxy [::String]
|
549
629
|
# Name of the TargetHttpsProxy resource to set the QUIC override policy for. The name should conform to RFC1035.
|
550
|
-
# @yield [result,
|
551
|
-
# @yieldparam result [::
|
630
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
631
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
552
632
|
# @yieldparam response [::Faraday::Response]
|
553
633
|
#
|
554
|
-
# @return [::
|
634
|
+
# @return [::Gapic::Rest::BaseOperation]
|
555
635
|
#
|
556
636
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
557
637
|
def set_quic_override request, options = nil
|
@@ -563,7 +643,7 @@ module Google
|
|
563
643
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
564
644
|
|
565
645
|
# Customize the options with defaults
|
566
|
-
call_metadata =
|
646
|
+
call_metadata = @config.rpcs.set_quic_override.metadata.to_h
|
567
647
|
|
568
648
|
# Set x-goog-api-client header
|
569
649
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -571,20 +651,17 @@ module Google
|
|
571
651
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
572
652
|
transports_version_send: [:rest]
|
573
653
|
|
574
|
-
options.apply_defaults timeout: @config.timeout,
|
654
|
+
options.apply_defaults timeout: @config.rpcs.set_quic_override.timeout,
|
575
655
|
metadata: call_metadata
|
576
656
|
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
yield result, response if block_given?
|
587
|
-
result
|
657
|
+
options.apply_defaults timeout: @config.timeout,
|
658
|
+
metadata: @config.metadata
|
659
|
+
|
660
|
+
@target_https_proxies_stub.set_quic_override request, options do |result, response|
|
661
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
662
|
+
yield result, response if block_given?
|
663
|
+
return result
|
664
|
+
end
|
588
665
|
rescue ::Faraday::Error => e
|
589
666
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
590
667
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -622,11 +699,11 @@ module Google
|
|
622
699
|
# The body resource for this request
|
623
700
|
# @param target_https_proxy [::String]
|
624
701
|
# Name of the TargetHttpsProxy resource to set an SslCertificates resource for.
|
625
|
-
# @yield [result,
|
626
|
-
# @yieldparam result [::
|
702
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
703
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
627
704
|
# @yieldparam response [::Faraday::Response]
|
628
705
|
#
|
629
|
-
# @return [::
|
706
|
+
# @return [::Gapic::Rest::BaseOperation]
|
630
707
|
#
|
631
708
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
632
709
|
def set_ssl_certificates request, options = nil
|
@@ -638,7 +715,7 @@ module Google
|
|
638
715
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
639
716
|
|
640
717
|
# Customize the options with defaults
|
641
|
-
call_metadata =
|
718
|
+
call_metadata = @config.rpcs.set_ssl_certificates.metadata.to_h
|
642
719
|
|
643
720
|
# Set x-goog-api-client header
|
644
721
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -646,20 +723,17 @@ module Google
|
|
646
723
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
647
724
|
transports_version_send: [:rest]
|
648
725
|
|
649
|
-
options.apply_defaults timeout: @config.timeout,
|
726
|
+
options.apply_defaults timeout: @config.rpcs.set_ssl_certificates.timeout,
|
650
727
|
metadata: call_metadata
|
651
728
|
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
|
661
|
-
yield result, response if block_given?
|
662
|
-
result
|
729
|
+
options.apply_defaults timeout: @config.timeout,
|
730
|
+
metadata: @config.metadata
|
731
|
+
|
732
|
+
@target_https_proxies_stub.set_ssl_certificates request, options do |result, response|
|
733
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
734
|
+
yield result, response if block_given?
|
735
|
+
return result
|
736
|
+
end
|
663
737
|
rescue ::Faraday::Error => e
|
664
738
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
665
739
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -697,11 +771,11 @@ module Google
|
|
697
771
|
# The body resource for this request
|
698
772
|
# @param target_https_proxy [::String]
|
699
773
|
# Name of the TargetHttpsProxy resource whose SSL policy is to be set. The name must be 1-63 characters long, and comply with RFC1035.
|
700
|
-
# @yield [result,
|
701
|
-
# @yieldparam result [::
|
774
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
775
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
702
776
|
# @yieldparam response [::Faraday::Response]
|
703
777
|
#
|
704
|
-
# @return [::
|
778
|
+
# @return [::Gapic::Rest::BaseOperation]
|
705
779
|
#
|
706
780
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
707
781
|
def set_ssl_policy request, options = nil
|
@@ -713,7 +787,7 @@ module Google
|
|
713
787
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
714
788
|
|
715
789
|
# Customize the options with defaults
|
716
|
-
call_metadata =
|
790
|
+
call_metadata = @config.rpcs.set_ssl_policy.metadata.to_h
|
717
791
|
|
718
792
|
# Set x-goog-api-client header
|
719
793
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -721,20 +795,17 @@ module Google
|
|
721
795
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
722
796
|
transports_version_send: [:rest]
|
723
797
|
|
724
|
-
options.apply_defaults timeout: @config.timeout,
|
798
|
+
options.apply_defaults timeout: @config.rpcs.set_ssl_policy.timeout,
|
725
799
|
metadata: call_metadata
|
726
800
|
|
727
|
-
|
728
|
-
|
729
|
-
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
|
734
|
-
|
735
|
-
|
736
|
-
yield result, response if block_given?
|
737
|
-
result
|
801
|
+
options.apply_defaults timeout: @config.timeout,
|
802
|
+
metadata: @config.metadata
|
803
|
+
|
804
|
+
@target_https_proxies_stub.set_ssl_policy request, options do |result, response|
|
805
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
806
|
+
yield result, response if block_given?
|
807
|
+
return result
|
808
|
+
end
|
738
809
|
rescue ::Faraday::Error => e
|
739
810
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
740
811
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -772,11 +843,11 @@ module Google
|
|
772
843
|
# Name of the TargetHttpsProxy resource whose URL map is to be set.
|
773
844
|
# @param url_map_reference_resource [::Google::Cloud::Compute::V1::UrlMapReference, ::Hash]
|
774
845
|
# The body resource for this request
|
775
|
-
# @yield [result,
|
776
|
-
# @yieldparam result [::
|
846
|
+
# @yield [result, response] Access the result along with the Faraday response object
|
847
|
+
# @yieldparam result [::Gapic::Rest::BaseOperation]
|
777
848
|
# @yieldparam response [::Faraday::Response]
|
778
849
|
#
|
779
|
-
# @return [::
|
850
|
+
# @return [::Gapic::Rest::BaseOperation]
|
780
851
|
#
|
781
852
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
782
853
|
def set_url_map request, options = nil
|
@@ -788,7 +859,7 @@ module Google
|
|
788
859
|
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
789
860
|
|
790
861
|
# Customize the options with defaults
|
791
|
-
call_metadata =
|
862
|
+
call_metadata = @config.rpcs.set_url_map.metadata.to_h
|
792
863
|
|
793
864
|
# Set x-goog-api-client header
|
794
865
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
@@ -796,20 +867,17 @@ module Google
|
|
796
867
|
gapic_version: ::Google::Cloud::Compute::V1::VERSION,
|
797
868
|
transports_version_send: [:rest]
|
798
869
|
|
799
|
-
options.apply_defaults timeout: @config.timeout,
|
870
|
+
options.apply_defaults timeout: @config.rpcs.set_url_map.timeout,
|
800
871
|
metadata: call_metadata
|
801
872
|
|
802
|
-
|
803
|
-
|
804
|
-
|
805
|
-
|
806
|
-
|
807
|
-
|
808
|
-
|
809
|
-
|
810
|
-
|
811
|
-
yield result, response if block_given?
|
812
|
-
result
|
873
|
+
options.apply_defaults timeout: @config.timeout,
|
874
|
+
metadata: @config.metadata
|
875
|
+
|
876
|
+
@target_https_proxies_stub.set_url_map request, options do |result, response|
|
877
|
+
result = ::Gapic::Rest::BaseOperation.new result
|
878
|
+
yield result, response if block_given?
|
879
|
+
return result
|
880
|
+
end
|
813
881
|
rescue ::Faraday::Error => e
|
814
882
|
gapic_error = ::Gapic::Rest::Error.wrap_faraday_error e
|
815
883
|
raise ::Google::Cloud::Error.from_error(gapic_error)
|
@@ -864,6 +932,9 @@ module Google
|
|
864
932
|
# @!attribute [rw] timeout
|
865
933
|
# The call timeout in seconds.
|
866
934
|
# @return [::Numeric]
|
935
|
+
# @!attribute [rw] metadata
|
936
|
+
# Additional REST headers to be sent with the call.
|
937
|
+
# @return [::Hash{::Symbol=>::String}]
|
867
938
|
#
|
868
939
|
class Configuration
|
869
940
|
extend ::Gapic::Config
|
@@ -877,6 +948,7 @@ module Google
|
|
877
948
|
config_attr :lib_name, nil, ::String, nil
|
878
949
|
config_attr :lib_version, nil, ::String, nil
|
879
950
|
config_attr :timeout, nil, ::Numeric, nil
|
951
|
+
config_attr :metadata, nil, ::Hash, nil
|
880
952
|
|
881
953
|
# @private
|
882
954
|
def initialize parent_config = nil
|
@@ -884,6 +956,109 @@ module Google
|
|
884
956
|
|
885
957
|
yield self if block_given?
|
886
958
|
end
|
959
|
+
|
960
|
+
##
|
961
|
+
# Configurations for individual RPCs
|
962
|
+
# @return [Rpcs]
|
963
|
+
#
|
964
|
+
def rpcs
|
965
|
+
@rpcs ||= begin
|
966
|
+
parent_rpcs = nil
|
967
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
968
|
+
Rpcs.new parent_rpcs
|
969
|
+
end
|
970
|
+
end
|
971
|
+
|
972
|
+
##
|
973
|
+
# Configuration RPC class for the TargetHttpsProxies API.
|
974
|
+
#
|
975
|
+
# Includes fields providing the configuration for each RPC in this service.
|
976
|
+
# Each configuration object is of type `Gapic::Config::Method` and includes
|
977
|
+
# the following configuration fields:
|
978
|
+
#
|
979
|
+
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
980
|
+
#
|
981
|
+
# there is one other field (`retry_policy`) that can be set
|
982
|
+
# but is currently not supported for REST Gapic libraries.
|
983
|
+
#
|
984
|
+
class Rpcs
|
985
|
+
##
|
986
|
+
# RPC-specific configuration for `aggregated_list`
|
987
|
+
# @return [::Gapic::Config::Method]
|
988
|
+
#
|
989
|
+
attr_reader :aggregated_list
|
990
|
+
##
|
991
|
+
# RPC-specific configuration for `delete`
|
992
|
+
# @return [::Gapic::Config::Method]
|
993
|
+
#
|
994
|
+
attr_reader :delete
|
995
|
+
##
|
996
|
+
# RPC-specific configuration for `get`
|
997
|
+
# @return [::Gapic::Config::Method]
|
998
|
+
#
|
999
|
+
attr_reader :get
|
1000
|
+
##
|
1001
|
+
# RPC-specific configuration for `insert`
|
1002
|
+
# @return [::Gapic::Config::Method]
|
1003
|
+
#
|
1004
|
+
attr_reader :insert
|
1005
|
+
##
|
1006
|
+
# RPC-specific configuration for `list`
|
1007
|
+
# @return [::Gapic::Config::Method]
|
1008
|
+
#
|
1009
|
+
attr_reader :list
|
1010
|
+
##
|
1011
|
+
# RPC-specific configuration for `patch`
|
1012
|
+
# @return [::Gapic::Config::Method]
|
1013
|
+
#
|
1014
|
+
attr_reader :patch
|
1015
|
+
##
|
1016
|
+
# RPC-specific configuration for `set_quic_override`
|
1017
|
+
# @return [::Gapic::Config::Method]
|
1018
|
+
#
|
1019
|
+
attr_reader :set_quic_override
|
1020
|
+
##
|
1021
|
+
# RPC-specific configuration for `set_ssl_certificates`
|
1022
|
+
# @return [::Gapic::Config::Method]
|
1023
|
+
#
|
1024
|
+
attr_reader :set_ssl_certificates
|
1025
|
+
##
|
1026
|
+
# RPC-specific configuration for `set_ssl_policy`
|
1027
|
+
# @return [::Gapic::Config::Method]
|
1028
|
+
#
|
1029
|
+
attr_reader :set_ssl_policy
|
1030
|
+
##
|
1031
|
+
# RPC-specific configuration for `set_url_map`
|
1032
|
+
# @return [::Gapic::Config::Method]
|
1033
|
+
#
|
1034
|
+
attr_reader :set_url_map
|
1035
|
+
|
1036
|
+
# @private
|
1037
|
+
def initialize parent_rpcs = nil
|
1038
|
+
aggregated_list_config = parent_rpcs.aggregated_list if parent_rpcs.respond_to? :aggregated_list
|
1039
|
+
@aggregated_list = ::Gapic::Config::Method.new aggregated_list_config
|
1040
|
+
delete_config = parent_rpcs.delete if parent_rpcs.respond_to? :delete
|
1041
|
+
@delete = ::Gapic::Config::Method.new delete_config
|
1042
|
+
get_config = parent_rpcs.get if parent_rpcs.respond_to? :get
|
1043
|
+
@get = ::Gapic::Config::Method.new get_config
|
1044
|
+
insert_config = parent_rpcs.insert if parent_rpcs.respond_to? :insert
|
1045
|
+
@insert = ::Gapic::Config::Method.new insert_config
|
1046
|
+
list_config = parent_rpcs.list if parent_rpcs.respond_to? :list
|
1047
|
+
@list = ::Gapic::Config::Method.new list_config
|
1048
|
+
patch_config = parent_rpcs.patch if parent_rpcs.respond_to? :patch
|
1049
|
+
@patch = ::Gapic::Config::Method.new patch_config
|
1050
|
+
set_quic_override_config = parent_rpcs.set_quic_override if parent_rpcs.respond_to? :set_quic_override
|
1051
|
+
@set_quic_override = ::Gapic::Config::Method.new set_quic_override_config
|
1052
|
+
set_ssl_certificates_config = parent_rpcs.set_ssl_certificates if parent_rpcs.respond_to? :set_ssl_certificates
|
1053
|
+
@set_ssl_certificates = ::Gapic::Config::Method.new set_ssl_certificates_config
|
1054
|
+
set_ssl_policy_config = parent_rpcs.set_ssl_policy if parent_rpcs.respond_to? :set_ssl_policy
|
1055
|
+
@set_ssl_policy = ::Gapic::Config::Method.new set_ssl_policy_config
|
1056
|
+
set_url_map_config = parent_rpcs.set_url_map if parent_rpcs.respond_to? :set_url_map
|
1057
|
+
@set_url_map = ::Gapic::Config::Method.new set_url_map_config
|
1058
|
+
|
1059
|
+
yield self if block_given?
|
1060
|
+
end
|
1061
|
+
end
|
887
1062
|
end
|
888
1063
|
end
|
889
1064
|
end
|