google-cloud-compute-v1 1.1.0 → 1.2.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/addresses/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +83 -21
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +93 -24
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +90 -21
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +97 -30
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +53 -12
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +68 -15
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +63 -15
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +53 -12
- data/lib/google/cloud/compute/v1/global_operations/rest/nonstandard_lro.rb +68 -0
- data/lib/google/cloud/compute/v1/global_operations.rb +1 -0
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/nonstandard_lro.rb +68 -0
- data/lib/google/cloud/compute/v1/global_organization_operations.rb +1 -0
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +53 -12
- data/lib/google/cloud/compute/v1/images/rest/client.rb +63 -15
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +167 -42
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +68 -15
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +365 -96
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +83 -21
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +79 -18
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +103 -27
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +90 -21
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +167 -42
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +24 -3
- data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +24 -3
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/region_operations/rest/nonstandard_lro.rb +68 -0
- data/lib/google/cloud/compute/v1/region_operations.rb +1 -0
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +57 -12
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +73 -18
- data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +33 -6
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +68 -15
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +43 -9
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +53 -12
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +83 -21
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +90 -21
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +73 -18
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +53 -12
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +63 -15
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +46 -9
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +35 -6
- data/lib/google/cloud/compute/v1/zone_operations/rest/nonstandard_lro.rb +68 -0
- data/lib/google/cloud/compute/v1/zone_operations.rb +1 -0
- data/lib/google/cloud/compute/v1.rb +2 -0
- metadata +6 -2
@@ -19,6 +19,7 @@
|
|
19
19
|
require "google/cloud/errors"
|
20
20
|
require "google/cloud/compute/v1/compute_pb"
|
21
21
|
require "google/cloud/compute/v1/networks/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/global_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -154,9 +155,21 @@ module Google
|
|
154
155
|
credentials = Credentials.new credentials, scope: @config.scope
|
155
156
|
end
|
156
157
|
|
158
|
+
@global_operations = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::Client.new do |config|
|
159
|
+
config.credentials = credentials
|
160
|
+
config.endpoint = @config.endpoint
|
161
|
+
end
|
162
|
+
|
157
163
|
@networks_stub = ::Google::Cloud::Compute::V1::Networks::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
158
164
|
end
|
159
165
|
|
166
|
+
##
|
167
|
+
# Get the associated client for long-running operations via GlobalOperations.
|
168
|
+
#
|
169
|
+
# @return [::Google::Cloud::Compute::V1::GlobalOperations::Rest::Client]
|
170
|
+
#
|
171
|
+
attr_reader :global_operations
|
172
|
+
|
160
173
|
# Service calls
|
161
174
|
|
162
175
|
##
|
@@ -188,10 +201,10 @@ module Google
|
|
188
201
|
# @param request_id [::String]
|
189
202
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
190
203
|
# @yield [result, response] Access the result along with the Faraday response object
|
191
|
-
# @yieldparam result [::Gapic::
|
204
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
192
205
|
# @yieldparam response [::Faraday::Response]
|
193
206
|
#
|
194
|
-
# @return [::Gapic::
|
207
|
+
# @return [::Gapic::GenericLRO::Operation]
|
195
208
|
#
|
196
209
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
197
210
|
def add_peering request, options = nil
|
@@ -218,7 +231,14 @@ module Google
|
|
218
231
|
metadata: @config.metadata
|
219
232
|
|
220
233
|
@networks_stub.add_peering request, options do |result, response|
|
221
|
-
result = ::
|
234
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
235
|
+
operation: result,
|
236
|
+
client: global_operations,
|
237
|
+
request_values: {
|
238
|
+
"project" => request.project
|
239
|
+
},
|
240
|
+
options: options
|
241
|
+
)
|
222
242
|
yield result, response if block_given?
|
223
243
|
return result
|
224
244
|
end
|
@@ -254,10 +274,10 @@ module Google
|
|
254
274
|
# @param request_id [::String]
|
255
275
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
256
276
|
# @yield [result, response] Access the result along with the Faraday response object
|
257
|
-
# @yieldparam result [::Gapic::
|
277
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
258
278
|
# @yieldparam response [::Faraday::Response]
|
259
279
|
#
|
260
|
-
# @return [::Gapic::
|
280
|
+
# @return [::Gapic::GenericLRO::Operation]
|
261
281
|
#
|
262
282
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
263
283
|
def delete request, options = nil
|
@@ -284,7 +304,14 @@ module Google
|
|
284
304
|
metadata: @config.metadata
|
285
305
|
|
286
306
|
@networks_stub.delete request, options do |result, response|
|
287
|
-
result = ::
|
307
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
308
|
+
operation: result,
|
309
|
+
client: global_operations,
|
310
|
+
request_values: {
|
311
|
+
"project" => request.project
|
312
|
+
},
|
313
|
+
options: options
|
314
|
+
)
|
288
315
|
yield result, response if block_given?
|
289
316
|
return result
|
290
317
|
end
|
@@ -446,10 +473,10 @@ module Google
|
|
446
473
|
# @param request_id [::String]
|
447
474
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
448
475
|
# @yield [result, response] Access the result along with the Faraday response object
|
449
|
-
# @yieldparam result [::Gapic::
|
476
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
450
477
|
# @yieldparam response [::Faraday::Response]
|
451
478
|
#
|
452
|
-
# @return [::Gapic::
|
479
|
+
# @return [::Gapic::GenericLRO::Operation]
|
453
480
|
#
|
454
481
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
455
482
|
def insert request, options = nil
|
@@ -476,7 +503,14 @@ module Google
|
|
476
503
|
metadata: @config.metadata
|
477
504
|
|
478
505
|
@networks_stub.insert request, options do |result, response|
|
479
|
-
result = ::
|
506
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
507
|
+
operation: result,
|
508
|
+
client: global_operations,
|
509
|
+
request_values: {
|
510
|
+
"project" => request.project
|
511
|
+
},
|
512
|
+
options: options
|
513
|
+
)
|
480
514
|
yield result, response if block_given?
|
481
515
|
return result
|
482
516
|
end
|
@@ -667,10 +701,10 @@ module Google
|
|
667
701
|
# @param request_id [::String]
|
668
702
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
669
703
|
# @yield [result, response] Access the result along with the Faraday response object
|
670
|
-
# @yieldparam result [::Gapic::
|
704
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
671
705
|
# @yieldparam response [::Faraday::Response]
|
672
706
|
#
|
673
|
-
# @return [::Gapic::
|
707
|
+
# @return [::Gapic::GenericLRO::Operation]
|
674
708
|
#
|
675
709
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
676
710
|
def patch request, options = nil
|
@@ -697,7 +731,14 @@ module Google
|
|
697
731
|
metadata: @config.metadata
|
698
732
|
|
699
733
|
@networks_stub.patch request, options do |result, response|
|
700
|
-
result = ::
|
734
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
735
|
+
operation: result,
|
736
|
+
client: global_operations,
|
737
|
+
request_values: {
|
738
|
+
"project" => request.project
|
739
|
+
},
|
740
|
+
options: options
|
741
|
+
)
|
701
742
|
yield result, response if block_given?
|
702
743
|
return result
|
703
744
|
end
|
@@ -735,10 +776,10 @@ module Google
|
|
735
776
|
# @param request_id [::String]
|
736
777
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
737
778
|
# @yield [result, response] Access the result along with the Faraday response object
|
738
|
-
# @yieldparam result [::Gapic::
|
779
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
739
780
|
# @yieldparam response [::Faraday::Response]
|
740
781
|
#
|
741
|
-
# @return [::Gapic::
|
782
|
+
# @return [::Gapic::GenericLRO::Operation]
|
742
783
|
#
|
743
784
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
744
785
|
def remove_peering request, options = nil
|
@@ -765,7 +806,14 @@ module Google
|
|
765
806
|
metadata: @config.metadata
|
766
807
|
|
767
808
|
@networks_stub.remove_peering request, options do |result, response|
|
768
|
-
result = ::
|
809
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
810
|
+
operation: result,
|
811
|
+
client: global_operations,
|
812
|
+
request_values: {
|
813
|
+
"project" => request.project
|
814
|
+
},
|
815
|
+
options: options
|
816
|
+
)
|
769
817
|
yield result, response if block_given?
|
770
818
|
return result
|
771
819
|
end
|
@@ -801,10 +849,10 @@ module Google
|
|
801
849
|
# @param request_id [::String]
|
802
850
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
803
851
|
# @yield [result, response] Access the result along with the Faraday response object
|
804
|
-
# @yieldparam result [::Gapic::
|
852
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
805
853
|
# @yieldparam response [::Faraday::Response]
|
806
854
|
#
|
807
|
-
# @return [::Gapic::
|
855
|
+
# @return [::Gapic::GenericLRO::Operation]
|
808
856
|
#
|
809
857
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
810
858
|
def switch_to_custom_mode request, options = nil
|
@@ -831,7 +879,14 @@ module Google
|
|
831
879
|
metadata: @config.metadata
|
832
880
|
|
833
881
|
@networks_stub.switch_to_custom_mode request, options do |result, response|
|
834
|
-
result = ::
|
882
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
883
|
+
operation: result,
|
884
|
+
client: global_operations,
|
885
|
+
request_values: {
|
886
|
+
"project" => request.project
|
887
|
+
},
|
888
|
+
options: options
|
889
|
+
)
|
835
890
|
yield result, response if block_given?
|
836
891
|
return result
|
837
892
|
end
|
@@ -869,10 +924,10 @@ module Google
|
|
869
924
|
# @param request_id [::String]
|
870
925
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
871
926
|
# @yield [result, response] Access the result along with the Faraday response object
|
872
|
-
# @yieldparam result [::Gapic::
|
927
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
873
928
|
# @yieldparam response [::Faraday::Response]
|
874
929
|
#
|
875
|
-
# @return [::Gapic::
|
930
|
+
# @return [::Gapic::GenericLRO::Operation]
|
876
931
|
#
|
877
932
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
878
933
|
def update_peering request, options = nil
|
@@ -899,7 +954,14 @@ module Google
|
|
899
954
|
metadata: @config.metadata
|
900
955
|
|
901
956
|
@networks_stub.update_peering request, options do |result, response|
|
902
|
-
result = ::
|
957
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
958
|
+
operation: result,
|
959
|
+
client: global_operations,
|
960
|
+
request_values: {
|
961
|
+
"project" => request.project
|
962
|
+
},
|
963
|
+
options: options
|
964
|
+
)
|
903
965
|
yield result, response if block_given?
|
904
966
|
return result
|
905
967
|
end
|
@@ -19,6 +19,7 @@
|
|
19
19
|
require "google/cloud/errors"
|
20
20
|
require "google/cloud/compute/v1/compute_pb"
|
21
21
|
require "google/cloud/compute/v1/node_groups/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/zone_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -158,9 +159,21 @@ module Google
|
|
158
159
|
credentials = Credentials.new credentials, scope: @config.scope
|
159
160
|
end
|
160
161
|
|
162
|
+
@zone_operations = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::Client.new do |config|
|
163
|
+
config.credentials = credentials
|
164
|
+
config.endpoint = @config.endpoint
|
165
|
+
end
|
166
|
+
|
161
167
|
@node_groups_stub = ::Google::Cloud::Compute::V1::NodeGroups::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
162
168
|
end
|
163
169
|
|
170
|
+
##
|
171
|
+
# Get the associated client for long-running operations via ZoneOperations.
|
172
|
+
#
|
173
|
+
# @return [::Google::Cloud::Compute::V1::ZoneOperations::Rest::Client]
|
174
|
+
#
|
175
|
+
attr_reader :zone_operations
|
176
|
+
|
164
177
|
# Service calls
|
165
178
|
|
166
179
|
##
|
@@ -194,10 +207,10 @@ module Google
|
|
194
207
|
# @param zone [::String]
|
195
208
|
# The name of the zone for this request.
|
196
209
|
# @yield [result, response] Access the result along with the Faraday response object
|
197
|
-
# @yieldparam result [::Gapic::
|
210
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
198
211
|
# @yieldparam response [::Faraday::Response]
|
199
212
|
#
|
200
|
-
# @return [::Gapic::
|
213
|
+
# @return [::Gapic::GenericLRO::Operation]
|
201
214
|
#
|
202
215
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
203
216
|
def add_nodes request, options = nil
|
@@ -224,7 +237,15 @@ module Google
|
|
224
237
|
metadata: @config.metadata
|
225
238
|
|
226
239
|
@node_groups_stub.add_nodes request, options do |result, response|
|
227
|
-
result = ::
|
240
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
241
|
+
operation: result,
|
242
|
+
client: zone_operations,
|
243
|
+
request_values: {
|
244
|
+
"project" => request.project,
|
245
|
+
"zone" => request.zone
|
246
|
+
},
|
247
|
+
options: options
|
248
|
+
)
|
228
249
|
yield result, response if block_given?
|
229
250
|
return result
|
230
251
|
end
|
@@ -336,10 +357,10 @@ module Google
|
|
336
357
|
# @param zone [::String]
|
337
358
|
# The name of the zone for this request.
|
338
359
|
# @yield [result, response] Access the result along with the Faraday response object
|
339
|
-
# @yieldparam result [::Gapic::
|
360
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
340
361
|
# @yieldparam response [::Faraday::Response]
|
341
362
|
#
|
342
|
-
# @return [::Gapic::
|
363
|
+
# @return [::Gapic::GenericLRO::Operation]
|
343
364
|
#
|
344
365
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
345
366
|
def delete request, options = nil
|
@@ -366,7 +387,15 @@ module Google
|
|
366
387
|
metadata: @config.metadata
|
367
388
|
|
368
389
|
@node_groups_stub.delete request, options do |result, response|
|
369
|
-
result = ::
|
390
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
391
|
+
operation: result,
|
392
|
+
client: zone_operations,
|
393
|
+
request_values: {
|
394
|
+
"project" => request.project,
|
395
|
+
"zone" => request.zone
|
396
|
+
},
|
397
|
+
options: options
|
398
|
+
)
|
370
399
|
yield result, response if block_given?
|
371
400
|
return result
|
372
401
|
end
|
@@ -406,10 +435,10 @@ module Google
|
|
406
435
|
# @param zone [::String]
|
407
436
|
# The name of the zone for this request.
|
408
437
|
# @yield [result, response] Access the result along with the Faraday response object
|
409
|
-
# @yieldparam result [::Gapic::
|
438
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
410
439
|
# @yieldparam response [::Faraday::Response]
|
411
440
|
#
|
412
|
-
# @return [::Gapic::
|
441
|
+
# @return [::Gapic::GenericLRO::Operation]
|
413
442
|
#
|
414
443
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
415
444
|
def delete_nodes request, options = nil
|
@@ -436,7 +465,15 @@ module Google
|
|
436
465
|
metadata: @config.metadata
|
437
466
|
|
438
467
|
@node_groups_stub.delete_nodes request, options do |result, response|
|
439
|
-
result = ::
|
468
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
469
|
+
operation: result,
|
470
|
+
client: zone_operations,
|
471
|
+
request_values: {
|
472
|
+
"project" => request.project,
|
473
|
+
"zone" => request.zone
|
474
|
+
},
|
475
|
+
options: options
|
476
|
+
)
|
440
477
|
yield result, response if block_given?
|
441
478
|
return result
|
442
479
|
end
|
@@ -608,10 +645,10 @@ module Google
|
|
608
645
|
# @param zone [::String]
|
609
646
|
# The name of the zone for this request.
|
610
647
|
# @yield [result, response] Access the result along with the Faraday response object
|
611
|
-
# @yieldparam result [::Gapic::
|
648
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
612
649
|
# @yieldparam response [::Faraday::Response]
|
613
650
|
#
|
614
|
-
# @return [::Gapic::
|
651
|
+
# @return [::Gapic::GenericLRO::Operation]
|
615
652
|
#
|
616
653
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
617
654
|
def insert request, options = nil
|
@@ -638,7 +675,15 @@ module Google
|
|
638
675
|
metadata: @config.metadata
|
639
676
|
|
640
677
|
@node_groups_stub.insert request, options do |result, response|
|
641
|
-
result = ::
|
678
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
679
|
+
operation: result,
|
680
|
+
client: zone_operations,
|
681
|
+
request_values: {
|
682
|
+
"project" => request.project,
|
683
|
+
"zone" => request.zone
|
684
|
+
},
|
685
|
+
options: options
|
686
|
+
)
|
642
687
|
yield result, response if block_given?
|
643
688
|
return result
|
644
689
|
end
|
@@ -828,10 +873,10 @@ module Google
|
|
828
873
|
# @param zone [::String]
|
829
874
|
# The name of the zone for this request.
|
830
875
|
# @yield [result, response] Access the result along with the Faraday response object
|
831
|
-
# @yieldparam result [::Gapic::
|
876
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
832
877
|
# @yieldparam response [::Faraday::Response]
|
833
878
|
#
|
834
|
-
# @return [::Gapic::
|
879
|
+
# @return [::Gapic::GenericLRO::Operation]
|
835
880
|
#
|
836
881
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
837
882
|
def patch request, options = nil
|
@@ -858,7 +903,15 @@ module Google
|
|
858
903
|
metadata: @config.metadata
|
859
904
|
|
860
905
|
@node_groups_stub.patch request, options do |result, response|
|
861
|
-
result = ::
|
906
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
907
|
+
operation: result,
|
908
|
+
client: zone_operations,
|
909
|
+
request_values: {
|
910
|
+
"project" => request.project,
|
911
|
+
"zone" => request.zone
|
912
|
+
},
|
913
|
+
options: options
|
914
|
+
)
|
862
915
|
yield result, response if block_given?
|
863
916
|
return result
|
864
917
|
end
|
@@ -965,10 +1018,10 @@ module Google
|
|
965
1018
|
# @param zone [::String]
|
966
1019
|
# The name of the zone for this request.
|
967
1020
|
# @yield [result, response] Access the result along with the Faraday response object
|
968
|
-
# @yieldparam result [::Gapic::
|
1021
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
969
1022
|
# @yieldparam response [::Faraday::Response]
|
970
1023
|
#
|
971
|
-
# @return [::Gapic::
|
1024
|
+
# @return [::Gapic::GenericLRO::Operation]
|
972
1025
|
#
|
973
1026
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
974
1027
|
def set_node_template request, options = nil
|
@@ -995,7 +1048,15 @@ module Google
|
|
995
1048
|
metadata: @config.metadata
|
996
1049
|
|
997
1050
|
@node_groups_stub.set_node_template request, options do |result, response|
|
998
|
-
result = ::
|
1051
|
+
result = ::Google::Cloud::Compute::V1::ZoneOperations::Rest::NonstandardLro.create_operation(
|
1052
|
+
operation: result,
|
1053
|
+
client: zone_operations,
|
1054
|
+
request_values: {
|
1055
|
+
"project" => request.project,
|
1056
|
+
"zone" => request.zone
|
1057
|
+
},
|
1058
|
+
options: options
|
1059
|
+
)
|
999
1060
|
yield result, response if block_given?
|
1000
1061
|
return result
|
1001
1062
|
end
|
@@ -19,6 +19,7 @@
|
|
19
19
|
require "google/cloud/errors"
|
20
20
|
require "google/cloud/compute/v1/compute_pb"
|
21
21
|
require "google/cloud/compute/v1/node_templates/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/region_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -148,9 +149,21 @@ module Google
|
|
148
149
|
credentials = Credentials.new credentials, scope: @config.scope
|
149
150
|
end
|
150
151
|
|
152
|
+
@region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
|
153
|
+
config.credentials = credentials
|
154
|
+
config.endpoint = @config.endpoint
|
155
|
+
end
|
156
|
+
|
151
157
|
@node_templates_stub = ::Google::Cloud::Compute::V1::NodeTemplates::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
152
158
|
end
|
153
159
|
|
160
|
+
##
|
161
|
+
# Get the associated client for long-running operations via RegionOperations.
|
162
|
+
#
|
163
|
+
# @return [::Google::Cloud::Compute::V1::RegionOperations::Rest::Client]
|
164
|
+
#
|
165
|
+
attr_reader :region_operations
|
166
|
+
|
154
167
|
# Service calls
|
155
168
|
|
156
169
|
##
|
@@ -256,10 +269,10 @@ module Google
|
|
256
269
|
# @param request_id [::String]
|
257
270
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
258
271
|
# @yield [result, response] Access the result along with the Faraday response object
|
259
|
-
# @yieldparam result [::Gapic::
|
272
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
260
273
|
# @yieldparam response [::Faraday::Response]
|
261
274
|
#
|
262
|
-
# @return [::Gapic::
|
275
|
+
# @return [::Gapic::GenericLRO::Operation]
|
263
276
|
#
|
264
277
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
265
278
|
def delete request, options = nil
|
@@ -286,7 +299,15 @@ module Google
|
|
286
299
|
metadata: @config.metadata
|
287
300
|
|
288
301
|
@node_templates_stub.delete request, options do |result, response|
|
289
|
-
result = ::
|
302
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
303
|
+
operation: result,
|
304
|
+
client: region_operations,
|
305
|
+
request_values: {
|
306
|
+
"project" => request.project,
|
307
|
+
"region" => request.region
|
308
|
+
},
|
309
|
+
options: options
|
310
|
+
)
|
290
311
|
yield result, response if block_given?
|
291
312
|
return result
|
292
313
|
end
|
@@ -456,10 +477,10 @@ module Google
|
|
456
477
|
# @param request_id [::String]
|
457
478
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
458
479
|
# @yield [result, response] Access the result along with the Faraday response object
|
459
|
-
# @yieldparam result [::Gapic::
|
480
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
460
481
|
# @yieldparam response [::Faraday::Response]
|
461
482
|
#
|
462
|
-
# @return [::Gapic::
|
483
|
+
# @return [::Gapic::GenericLRO::Operation]
|
463
484
|
#
|
464
485
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
465
486
|
def insert request, options = nil
|
@@ -486,7 +507,15 @@ module Google
|
|
486
507
|
metadata: @config.metadata
|
487
508
|
|
488
509
|
@node_templates_stub.insert request, options do |result, response|
|
489
|
-
result = ::
|
510
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
511
|
+
operation: result,
|
512
|
+
client: region_operations,
|
513
|
+
request_values: {
|
514
|
+
"project" => request.project,
|
515
|
+
"region" => request.region
|
516
|
+
},
|
517
|
+
options: options
|
518
|
+
)
|
490
519
|
yield result, response if block_given?
|
491
520
|
return result
|
492
521
|
end
|
@@ -19,6 +19,7 @@
|
|
19
19
|
require "google/cloud/errors"
|
20
20
|
require "google/cloud/compute/v1/compute_pb"
|
21
21
|
require "google/cloud/compute/v1/packet_mirrorings/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/region_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -143,9 +144,21 @@ module Google
|
|
143
144
|
credentials = Credentials.new credentials, scope: @config.scope
|
144
145
|
end
|
145
146
|
|
147
|
+
@region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
|
148
|
+
config.credentials = credentials
|
149
|
+
config.endpoint = @config.endpoint
|
150
|
+
end
|
151
|
+
|
146
152
|
@packet_mirrorings_stub = ::Google::Cloud::Compute::V1::PacketMirrorings::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
147
153
|
end
|
148
154
|
|
155
|
+
##
|
156
|
+
# Get the associated client for long-running operations via RegionOperations.
|
157
|
+
#
|
158
|
+
# @return [::Google::Cloud::Compute::V1::RegionOperations::Rest::Client]
|
159
|
+
#
|
160
|
+
attr_reader :region_operations
|
161
|
+
|
149
162
|
# Service calls
|
150
163
|
|
151
164
|
##
|
@@ -251,10 +264,10 @@ module Google
|
|
251
264
|
# @param request_id [::String]
|
252
265
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
253
266
|
# @yield [result, response] Access the result along with the Faraday response object
|
254
|
-
# @yieldparam result [::Gapic::
|
267
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
255
268
|
# @yieldparam response [::Faraday::Response]
|
256
269
|
#
|
257
|
-
# @return [::Gapic::
|
270
|
+
# @return [::Gapic::GenericLRO::Operation]
|
258
271
|
#
|
259
272
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
260
273
|
def delete request, options = nil
|
@@ -281,7 +294,15 @@ module Google
|
|
281
294
|
metadata: @config.metadata
|
282
295
|
|
283
296
|
@packet_mirrorings_stub.delete request, options do |result, response|
|
284
|
-
result = ::
|
297
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
298
|
+
operation: result,
|
299
|
+
client: region_operations,
|
300
|
+
request_values: {
|
301
|
+
"project" => request.project,
|
302
|
+
"region" => request.region
|
303
|
+
},
|
304
|
+
options: options
|
305
|
+
)
|
285
306
|
yield result, response if block_given?
|
286
307
|
return result
|
287
308
|
end
|
@@ -384,10 +405,10 @@ module Google
|
|
384
405
|
# @param request_id [::String]
|
385
406
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
386
407
|
# @yield [result, response] Access the result along with the Faraday response object
|
387
|
-
# @yieldparam result [::Gapic::
|
408
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
388
409
|
# @yieldparam response [::Faraday::Response]
|
389
410
|
#
|
390
|
-
# @return [::Gapic::
|
411
|
+
# @return [::Gapic::GenericLRO::Operation]
|
391
412
|
#
|
392
413
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
393
414
|
def insert request, options = nil
|
@@ -414,7 +435,15 @@ module Google
|
|
414
435
|
metadata: @config.metadata
|
415
436
|
|
416
437
|
@packet_mirrorings_stub.insert request, options do |result, response|
|
417
|
-
result = ::
|
438
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
439
|
+
operation: result,
|
440
|
+
client: region_operations,
|
441
|
+
request_values: {
|
442
|
+
"project" => request.project,
|
443
|
+
"region" => request.region
|
444
|
+
},
|
445
|
+
options: options
|
446
|
+
)
|
418
447
|
yield result, response if block_given?
|
419
448
|
return result
|
420
449
|
end
|
@@ -528,10 +557,10 @@ module Google
|
|
528
557
|
# @param request_id [::String]
|
529
558
|
# 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. 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. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
|
530
559
|
# @yield [result, response] Access the result along with the Faraday response object
|
531
|
-
# @yieldparam result [::Gapic::
|
560
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
532
561
|
# @yieldparam response [::Faraday::Response]
|
533
562
|
#
|
534
|
-
# @return [::Gapic::
|
563
|
+
# @return [::Gapic::GenericLRO::Operation]
|
535
564
|
#
|
536
565
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
537
566
|
def patch request, options = nil
|
@@ -558,7 +587,15 @@ module Google
|
|
558
587
|
metadata: @config.metadata
|
559
588
|
|
560
589
|
@packet_mirrorings_stub.patch request, options do |result, response|
|
561
|
-
result = ::
|
590
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
591
|
+
operation: result,
|
592
|
+
client: region_operations,
|
593
|
+
request_values: {
|
594
|
+
"project" => request.project,
|
595
|
+
"region" => request.region
|
596
|
+
},
|
597
|
+
options: options
|
598
|
+
)
|
562
599
|
yield result, response if block_given?
|
563
600
|
return result
|
564
601
|
end
|