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/firewall_policies/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/global_organization_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -174,9 +175,21 @@ module Google
|
|
174
175
|
credentials = Credentials.new credentials, scope: @config.scope
|
175
176
|
end
|
176
177
|
|
178
|
+
@global_organization_operations = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::Client.new do |config|
|
179
|
+
config.credentials = credentials
|
180
|
+
config.endpoint = @config.endpoint
|
181
|
+
end
|
182
|
+
|
177
183
|
@firewall_policies_stub = ::Google::Cloud::Compute::V1::FirewallPolicies::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
178
184
|
end
|
179
185
|
|
186
|
+
##
|
187
|
+
# Get the associated client for long-running operations via GlobalOrganizationOperations.
|
188
|
+
#
|
189
|
+
# @return [::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::Client]
|
190
|
+
#
|
191
|
+
attr_reader :global_organization_operations
|
192
|
+
|
180
193
|
# Service calls
|
181
194
|
|
182
195
|
##
|
@@ -208,10 +221,10 @@ module Google
|
|
208
221
|
# @param request_id [::String]
|
209
222
|
# 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).
|
210
223
|
# @yield [result, response] Access the result along with the Faraday response object
|
211
|
-
# @yieldparam result [::Gapic::
|
224
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
212
225
|
# @yieldparam response [::Faraday::Response]
|
213
226
|
#
|
214
|
-
# @return [::Gapic::
|
227
|
+
# @return [::Gapic::GenericLRO::Operation]
|
215
228
|
#
|
216
229
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
217
230
|
def add_association request, options = nil
|
@@ -238,7 +251,12 @@ module Google
|
|
238
251
|
metadata: @config.metadata
|
239
252
|
|
240
253
|
@firewall_policies_stub.add_association request, options do |result, response|
|
241
|
-
result = ::
|
254
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
255
|
+
operation: result,
|
256
|
+
client: global_organization_operations,
|
257
|
+
request_values: {},
|
258
|
+
options: options
|
259
|
+
)
|
242
260
|
yield result, response if block_given?
|
243
261
|
return result
|
244
262
|
end
|
@@ -274,10 +292,10 @@ module Google
|
|
274
292
|
# @param request_id [::String]
|
275
293
|
# 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).
|
276
294
|
# @yield [result, response] Access the result along with the Faraday response object
|
277
|
-
# @yieldparam result [::Gapic::
|
295
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
278
296
|
# @yieldparam response [::Faraday::Response]
|
279
297
|
#
|
280
|
-
# @return [::Gapic::
|
298
|
+
# @return [::Gapic::GenericLRO::Operation]
|
281
299
|
#
|
282
300
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
283
301
|
def add_rule request, options = nil
|
@@ -304,7 +322,12 @@ module Google
|
|
304
322
|
metadata: @config.metadata
|
305
323
|
|
306
324
|
@firewall_policies_stub.add_rule request, options do |result, response|
|
307
|
-
result = ::
|
325
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
326
|
+
operation: result,
|
327
|
+
client: global_organization_operations,
|
328
|
+
request_values: {},
|
329
|
+
options: options
|
330
|
+
)
|
308
331
|
yield result, response if block_given?
|
309
332
|
return result
|
310
333
|
end
|
@@ -340,10 +363,10 @@ module Google
|
|
340
363
|
# @param source_firewall_policy [::String]
|
341
364
|
# The firewall policy from which to copy rules.
|
342
365
|
# @yield [result, response] Access the result along with the Faraday response object
|
343
|
-
# @yieldparam result [::Gapic::
|
366
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
344
367
|
# @yieldparam response [::Faraday::Response]
|
345
368
|
#
|
346
|
-
# @return [::Gapic::
|
369
|
+
# @return [::Gapic::GenericLRO::Operation]
|
347
370
|
#
|
348
371
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
349
372
|
def clone_rules request, options = nil
|
@@ -370,7 +393,12 @@ module Google
|
|
370
393
|
metadata: @config.metadata
|
371
394
|
|
372
395
|
@firewall_policies_stub.clone_rules request, options do |result, response|
|
373
|
-
result = ::
|
396
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
397
|
+
operation: result,
|
398
|
+
client: global_organization_operations,
|
399
|
+
request_values: {},
|
400
|
+
options: options
|
401
|
+
)
|
374
402
|
yield result, response if block_given?
|
375
403
|
return result
|
376
404
|
end
|
@@ -404,10 +432,10 @@ module Google
|
|
404
432
|
# @param request_id [::String]
|
405
433
|
# 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).
|
406
434
|
# @yield [result, response] Access the result along with the Faraday response object
|
407
|
-
# @yieldparam result [::Gapic::
|
435
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
408
436
|
# @yieldparam response [::Faraday::Response]
|
409
437
|
#
|
410
|
-
# @return [::Gapic::
|
438
|
+
# @return [::Gapic::GenericLRO::Operation]
|
411
439
|
#
|
412
440
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
413
441
|
def delete request, options = nil
|
@@ -434,7 +462,12 @@ module Google
|
|
434
462
|
metadata: @config.metadata
|
435
463
|
|
436
464
|
@firewall_policies_stub.delete request, options do |result, response|
|
437
|
-
result = ::
|
465
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
466
|
+
operation: result,
|
467
|
+
client: global_organization_operations,
|
468
|
+
request_values: {},
|
469
|
+
options: options
|
470
|
+
)
|
438
471
|
yield result, response if block_given?
|
439
472
|
return result
|
440
473
|
end
|
@@ -720,10 +753,10 @@ module Google
|
|
720
753
|
# @param request_id [::String]
|
721
754
|
# 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).
|
722
755
|
# @yield [result, response] Access the result along with the Faraday response object
|
723
|
-
# @yieldparam result [::Gapic::
|
756
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
724
757
|
# @yieldparam response [::Faraday::Response]
|
725
758
|
#
|
726
|
-
# @return [::Gapic::
|
759
|
+
# @return [::Gapic::GenericLRO::Operation]
|
727
760
|
#
|
728
761
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
729
762
|
def insert request, options = nil
|
@@ -750,7 +783,14 @@ module Google
|
|
750
783
|
metadata: @config.metadata
|
751
784
|
|
752
785
|
@firewall_policies_stub.insert request, options do |result, response|
|
753
|
-
result = ::
|
786
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
787
|
+
operation: result,
|
788
|
+
client: global_organization_operations,
|
789
|
+
request_values: {
|
790
|
+
"parent_id" => request.parent_id
|
791
|
+
},
|
792
|
+
options: options
|
793
|
+
)
|
754
794
|
yield result, response if block_given?
|
755
795
|
return result
|
756
796
|
end
|
@@ -919,10 +959,10 @@ module Google
|
|
919
959
|
# @param request_id [::String]
|
920
960
|
# 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).
|
921
961
|
# @yield [result, response] Access the result along with the Faraday response object
|
922
|
-
# @yieldparam result [::Gapic::
|
962
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
923
963
|
# @yieldparam response [::Faraday::Response]
|
924
964
|
#
|
925
|
-
# @return [::Gapic::
|
965
|
+
# @return [::Gapic::GenericLRO::Operation]
|
926
966
|
#
|
927
967
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
928
968
|
def move request, options = nil
|
@@ -949,7 +989,14 @@ module Google
|
|
949
989
|
metadata: @config.metadata
|
950
990
|
|
951
991
|
@firewall_policies_stub.move request, options do |result, response|
|
952
|
-
result = ::
|
992
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
993
|
+
operation: result,
|
994
|
+
client: global_organization_operations,
|
995
|
+
request_values: {
|
996
|
+
"parent_id" => request.parent_id
|
997
|
+
},
|
998
|
+
options: options
|
999
|
+
)
|
953
1000
|
yield result, response if block_given?
|
954
1001
|
return result
|
955
1002
|
end
|
@@ -985,10 +1032,10 @@ module Google
|
|
985
1032
|
# @param request_id [::String]
|
986
1033
|
# 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).
|
987
1034
|
# @yield [result, response] Access the result along with the Faraday response object
|
988
|
-
# @yieldparam result [::Gapic::
|
1035
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
989
1036
|
# @yieldparam response [::Faraday::Response]
|
990
1037
|
#
|
991
|
-
# @return [::Gapic::
|
1038
|
+
# @return [::Gapic::GenericLRO::Operation]
|
992
1039
|
#
|
993
1040
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
994
1041
|
def patch request, options = nil
|
@@ -1015,7 +1062,12 @@ module Google
|
|
1015
1062
|
metadata: @config.metadata
|
1016
1063
|
|
1017
1064
|
@firewall_policies_stub.patch request, options do |result, response|
|
1018
|
-
result = ::
|
1065
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
1066
|
+
operation: result,
|
1067
|
+
client: global_organization_operations,
|
1068
|
+
request_values: {},
|
1069
|
+
options: options
|
1070
|
+
)
|
1019
1071
|
yield result, response if block_given?
|
1020
1072
|
return result
|
1021
1073
|
end
|
@@ -1053,10 +1105,10 @@ module Google
|
|
1053
1105
|
# @param request_id [::String]
|
1054
1106
|
# 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).
|
1055
1107
|
# @yield [result, response] Access the result along with the Faraday response object
|
1056
|
-
# @yieldparam result [::Gapic::
|
1108
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
1057
1109
|
# @yieldparam response [::Faraday::Response]
|
1058
1110
|
#
|
1059
|
-
# @return [::Gapic::
|
1111
|
+
# @return [::Gapic::GenericLRO::Operation]
|
1060
1112
|
#
|
1061
1113
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1062
1114
|
def patch_rule request, options = nil
|
@@ -1083,7 +1135,12 @@ module Google
|
|
1083
1135
|
metadata: @config.metadata
|
1084
1136
|
|
1085
1137
|
@firewall_policies_stub.patch_rule request, options do |result, response|
|
1086
|
-
result = ::
|
1138
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
1139
|
+
operation: result,
|
1140
|
+
client: global_organization_operations,
|
1141
|
+
request_values: {},
|
1142
|
+
options: options
|
1143
|
+
)
|
1087
1144
|
yield result, response if block_given?
|
1088
1145
|
return result
|
1089
1146
|
end
|
@@ -1119,10 +1176,10 @@ module Google
|
|
1119
1176
|
# @param request_id [::String]
|
1120
1177
|
# 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).
|
1121
1178
|
# @yield [result, response] Access the result along with the Faraday response object
|
1122
|
-
# @yieldparam result [::Gapic::
|
1179
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
1123
1180
|
# @yieldparam response [::Faraday::Response]
|
1124
1181
|
#
|
1125
|
-
# @return [::Gapic::
|
1182
|
+
# @return [::Gapic::GenericLRO::Operation]
|
1126
1183
|
#
|
1127
1184
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1128
1185
|
def remove_association request, options = nil
|
@@ -1149,7 +1206,12 @@ module Google
|
|
1149
1206
|
metadata: @config.metadata
|
1150
1207
|
|
1151
1208
|
@firewall_policies_stub.remove_association request, options do |result, response|
|
1152
|
-
result = ::
|
1209
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
1210
|
+
operation: result,
|
1211
|
+
client: global_organization_operations,
|
1212
|
+
request_values: {},
|
1213
|
+
options: options
|
1214
|
+
)
|
1153
1215
|
yield result, response if block_given?
|
1154
1216
|
return result
|
1155
1217
|
end
|
@@ -1185,10 +1247,10 @@ module Google
|
|
1185
1247
|
# @param request_id [::String]
|
1186
1248
|
# 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).
|
1187
1249
|
# @yield [result, response] Access the result along with the Faraday response object
|
1188
|
-
# @yieldparam result [::Gapic::
|
1250
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
1189
1251
|
# @yieldparam response [::Faraday::Response]
|
1190
1252
|
#
|
1191
|
-
# @return [::Gapic::
|
1253
|
+
# @return [::Gapic::GenericLRO::Operation]
|
1192
1254
|
#
|
1193
1255
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1194
1256
|
def remove_rule request, options = nil
|
@@ -1215,7 +1277,12 @@ module Google
|
|
1215
1277
|
metadata: @config.metadata
|
1216
1278
|
|
1217
1279
|
@firewall_policies_stub.remove_rule request, options do |result, response|
|
1218
|
-
result = ::
|
1280
|
+
result = ::Google::Cloud::Compute::V1::GlobalOrganizationOperations::Rest::NonstandardLro.create_operation(
|
1281
|
+
operation: result,
|
1282
|
+
client: global_organization_operations,
|
1283
|
+
request_values: {},
|
1284
|
+
options: options
|
1285
|
+
)
|
1219
1286
|
yield result, response if block_given?
|
1220
1287
|
return result
|
1221
1288
|
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/firewalls/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/global_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -138,9 +139,21 @@ module Google
|
|
138
139
|
credentials = Credentials.new credentials, scope: @config.scope
|
139
140
|
end
|
140
141
|
|
142
|
+
@global_operations = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::Client.new do |config|
|
143
|
+
config.credentials = credentials
|
144
|
+
config.endpoint = @config.endpoint
|
145
|
+
end
|
146
|
+
|
141
147
|
@firewalls_stub = ::Google::Cloud::Compute::V1::Firewalls::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
142
148
|
end
|
143
149
|
|
150
|
+
##
|
151
|
+
# Get the associated client for long-running operations via GlobalOperations.
|
152
|
+
#
|
153
|
+
# @return [::Google::Cloud::Compute::V1::GlobalOperations::Rest::Client]
|
154
|
+
#
|
155
|
+
attr_reader :global_operations
|
156
|
+
|
144
157
|
# Service calls
|
145
158
|
|
146
159
|
##
|
@@ -170,10 +183,10 @@ module Google
|
|
170
183
|
# @param request_id [::String]
|
171
184
|
# 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).
|
172
185
|
# @yield [result, response] Access the result along with the Faraday response object
|
173
|
-
# @yieldparam result [::Gapic::
|
186
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
174
187
|
# @yieldparam response [::Faraday::Response]
|
175
188
|
#
|
176
|
-
# @return [::Gapic::
|
189
|
+
# @return [::Gapic::GenericLRO::Operation]
|
177
190
|
#
|
178
191
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
179
192
|
def delete request, options = nil
|
@@ -200,7 +213,14 @@ module Google
|
|
200
213
|
metadata: @config.metadata
|
201
214
|
|
202
215
|
@firewalls_stub.delete request, options do |result, response|
|
203
|
-
result = ::
|
216
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
217
|
+
operation: result,
|
218
|
+
client: global_operations,
|
219
|
+
request_values: {
|
220
|
+
"project" => request.project
|
221
|
+
},
|
222
|
+
options: options
|
223
|
+
)
|
204
224
|
yield result, response if block_given?
|
205
225
|
return result
|
206
226
|
end
|
@@ -299,10 +319,10 @@ module Google
|
|
299
319
|
# @param request_id [::String]
|
300
320
|
# 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).
|
301
321
|
# @yield [result, response] Access the result along with the Faraday response object
|
302
|
-
# @yieldparam result [::Gapic::
|
322
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
303
323
|
# @yieldparam response [::Faraday::Response]
|
304
324
|
#
|
305
|
-
# @return [::Gapic::
|
325
|
+
# @return [::Gapic::GenericLRO::Operation]
|
306
326
|
#
|
307
327
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
308
328
|
def insert request, options = nil
|
@@ -329,7 +349,14 @@ module Google
|
|
329
349
|
metadata: @config.metadata
|
330
350
|
|
331
351
|
@firewalls_stub.insert request, options do |result, response|
|
332
|
-
result = ::
|
352
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
353
|
+
operation: result,
|
354
|
+
client: global_operations,
|
355
|
+
request_values: {
|
356
|
+
"project" => request.project
|
357
|
+
},
|
358
|
+
options: options
|
359
|
+
)
|
333
360
|
yield result, response if block_given?
|
334
361
|
return result
|
335
362
|
end
|
@@ -439,10 +466,10 @@ module Google
|
|
439
466
|
# @param request_id [::String]
|
440
467
|
# 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).
|
441
468
|
# @yield [result, response] Access the result along with the Faraday response object
|
442
|
-
# @yieldparam result [::Gapic::
|
469
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
443
470
|
# @yieldparam response [::Faraday::Response]
|
444
471
|
#
|
445
|
-
# @return [::Gapic::
|
472
|
+
# @return [::Gapic::GenericLRO::Operation]
|
446
473
|
#
|
447
474
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
448
475
|
def patch request, options = nil
|
@@ -469,7 +496,14 @@ module Google
|
|
469
496
|
metadata: @config.metadata
|
470
497
|
|
471
498
|
@firewalls_stub.patch request, options do |result, response|
|
472
|
-
result = ::
|
499
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
500
|
+
operation: result,
|
501
|
+
client: global_operations,
|
502
|
+
request_values: {
|
503
|
+
"project" => request.project
|
504
|
+
},
|
505
|
+
options: options
|
506
|
+
)
|
473
507
|
yield result, response if block_given?
|
474
508
|
return result
|
475
509
|
end
|
@@ -507,10 +541,10 @@ module Google
|
|
507
541
|
# @param request_id [::String]
|
508
542
|
# 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).
|
509
543
|
# @yield [result, response] Access the result along with the Faraday response object
|
510
|
-
# @yieldparam result [::Gapic::
|
544
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
511
545
|
# @yieldparam response [::Faraday::Response]
|
512
546
|
#
|
513
|
-
# @return [::Gapic::
|
547
|
+
# @return [::Gapic::GenericLRO::Operation]
|
514
548
|
#
|
515
549
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
516
550
|
def update request, options = nil
|
@@ -537,7 +571,14 @@ module Google
|
|
537
571
|
metadata: @config.metadata
|
538
572
|
|
539
573
|
@firewalls_stub.update request, options do |result, response|
|
540
|
-
result = ::
|
574
|
+
result = ::Google::Cloud::Compute::V1::GlobalOperations::Rest::NonstandardLro.create_operation(
|
575
|
+
operation: result,
|
576
|
+
client: global_operations,
|
577
|
+
request_values: {
|
578
|
+
"project" => request.project
|
579
|
+
},
|
580
|
+
options: options
|
581
|
+
)
|
541
582
|
yield result, response if block_given?
|
542
583
|
return result
|
543
584
|
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/forwarding_rules/rest/service_stub"
|
22
|
+
require "google/cloud/compute/v1/region_operations/rest"
|
22
23
|
|
23
24
|
module Google
|
24
25
|
module Cloud
|
@@ -145,9 +146,21 @@ module Google
|
|
145
146
|
credentials = Credentials.new credentials, scope: @config.scope
|
146
147
|
end
|
147
148
|
|
149
|
+
@region_operations = ::Google::Cloud::Compute::V1::RegionOperations::Rest::Client.new do |config|
|
150
|
+
config.credentials = credentials
|
151
|
+
config.endpoint = @config.endpoint
|
152
|
+
end
|
153
|
+
|
148
154
|
@forwarding_rules_stub = ::Google::Cloud::Compute::V1::ForwardingRules::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
149
155
|
end
|
150
156
|
|
157
|
+
##
|
158
|
+
# Get the associated client for long-running operations via RegionOperations.
|
159
|
+
#
|
160
|
+
# @return [::Google::Cloud::Compute::V1::RegionOperations::Rest::Client]
|
161
|
+
#
|
162
|
+
attr_reader :region_operations
|
163
|
+
|
151
164
|
# Service calls
|
152
165
|
|
153
166
|
##
|
@@ -253,10 +266,10 @@ module Google
|
|
253
266
|
# @param request_id [::String]
|
254
267
|
# 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).
|
255
268
|
# @yield [result, response] Access the result along with the Faraday response object
|
256
|
-
# @yieldparam result [::Gapic::
|
269
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
257
270
|
# @yieldparam response [::Faraday::Response]
|
258
271
|
#
|
259
|
-
# @return [::Gapic::
|
272
|
+
# @return [::Gapic::GenericLRO::Operation]
|
260
273
|
#
|
261
274
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
262
275
|
def delete request, options = nil
|
@@ -283,7 +296,15 @@ module Google
|
|
283
296
|
metadata: @config.metadata
|
284
297
|
|
285
298
|
@forwarding_rules_stub.delete request, options do |result, response|
|
286
|
-
result = ::
|
299
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
300
|
+
operation: result,
|
301
|
+
client: region_operations,
|
302
|
+
request_values: {
|
303
|
+
"project" => request.project,
|
304
|
+
"region" => request.region
|
305
|
+
},
|
306
|
+
options: options
|
307
|
+
)
|
287
308
|
yield result, response if block_given?
|
288
309
|
return result
|
289
310
|
end
|
@@ -386,10 +407,10 @@ module Google
|
|
386
407
|
# @param request_id [::String]
|
387
408
|
# 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).
|
388
409
|
# @yield [result, response] Access the result along with the Faraday response object
|
389
|
-
# @yieldparam result [::Gapic::
|
410
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
390
411
|
# @yieldparam response [::Faraday::Response]
|
391
412
|
#
|
392
|
-
# @return [::Gapic::
|
413
|
+
# @return [::Gapic::GenericLRO::Operation]
|
393
414
|
#
|
394
415
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
395
416
|
def insert request, options = nil
|
@@ -416,7 +437,15 @@ module Google
|
|
416
437
|
metadata: @config.metadata
|
417
438
|
|
418
439
|
@forwarding_rules_stub.insert request, options do |result, response|
|
419
|
-
result = ::
|
440
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
441
|
+
operation: result,
|
442
|
+
client: region_operations,
|
443
|
+
request_values: {
|
444
|
+
"project" => request.project,
|
445
|
+
"region" => request.region
|
446
|
+
},
|
447
|
+
options: options
|
448
|
+
)
|
420
449
|
yield result, response if block_given?
|
421
450
|
return result
|
422
451
|
end
|
@@ -530,10 +559,10 @@ module Google
|
|
530
559
|
# @param request_id [::String]
|
531
560
|
# 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).
|
532
561
|
# @yield [result, response] Access the result along with the Faraday response object
|
533
|
-
# @yieldparam result [::Gapic::
|
562
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
534
563
|
# @yieldparam response [::Faraday::Response]
|
535
564
|
#
|
536
|
-
# @return [::Gapic::
|
565
|
+
# @return [::Gapic::GenericLRO::Operation]
|
537
566
|
#
|
538
567
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
539
568
|
def patch request, options = nil
|
@@ -560,7 +589,15 @@ module Google
|
|
560
589
|
metadata: @config.metadata
|
561
590
|
|
562
591
|
@forwarding_rules_stub.patch request, options do |result, response|
|
563
|
-
result = ::
|
592
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
593
|
+
operation: result,
|
594
|
+
client: region_operations,
|
595
|
+
request_values: {
|
596
|
+
"project" => request.project,
|
597
|
+
"region" => request.region
|
598
|
+
},
|
599
|
+
options: options
|
600
|
+
)
|
564
601
|
yield result, response if block_given?
|
565
602
|
return result
|
566
603
|
end
|
@@ -600,10 +637,10 @@ module Google
|
|
600
637
|
# @param resource [::String]
|
601
638
|
# Name or id of the resource for this request.
|
602
639
|
# @yield [result, response] Access the result along with the Faraday response object
|
603
|
-
# @yieldparam result [::Gapic::
|
640
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
604
641
|
# @yieldparam response [::Faraday::Response]
|
605
642
|
#
|
606
|
-
# @return [::Gapic::
|
643
|
+
# @return [::Gapic::GenericLRO::Operation]
|
607
644
|
#
|
608
645
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
609
646
|
def set_labels request, options = nil
|
@@ -630,7 +667,15 @@ module Google
|
|
630
667
|
metadata: @config.metadata
|
631
668
|
|
632
669
|
@forwarding_rules_stub.set_labels request, options do |result, response|
|
633
|
-
result = ::
|
670
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
671
|
+
operation: result,
|
672
|
+
client: region_operations,
|
673
|
+
request_values: {
|
674
|
+
"project" => request.project,
|
675
|
+
"region" => request.region
|
676
|
+
},
|
677
|
+
options: options
|
678
|
+
)
|
634
679
|
yield result, response if block_given?
|
635
680
|
return result
|
636
681
|
end
|
@@ -670,10 +715,10 @@ module Google
|
|
670
715
|
# @param target_reference_resource [::Google::Cloud::Compute::V1::TargetReference, ::Hash]
|
671
716
|
# The body resource for this request
|
672
717
|
# @yield [result, response] Access the result along with the Faraday response object
|
673
|
-
# @yieldparam result [::Gapic::
|
718
|
+
# @yieldparam result [::Gapic::GenericLRO::Operation]
|
674
719
|
# @yieldparam response [::Faraday::Response]
|
675
720
|
#
|
676
|
-
# @return [::Gapic::
|
721
|
+
# @return [::Gapic::GenericLRO::Operation]
|
677
722
|
#
|
678
723
|
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
679
724
|
def set_target request, options = nil
|
@@ -700,7 +745,15 @@ module Google
|
|
700
745
|
metadata: @config.metadata
|
701
746
|
|
702
747
|
@forwarding_rules_stub.set_target request, options do |result, response|
|
703
|
-
result = ::
|
748
|
+
result = ::Google::Cloud::Compute::V1::RegionOperations::Rest::NonstandardLro.create_operation(
|
749
|
+
operation: result,
|
750
|
+
client: region_operations,
|
751
|
+
request_values: {
|
752
|
+
"project" => request.project,
|
753
|
+
"region" => request.region
|
754
|
+
},
|
755
|
+
options: options
|
756
|
+
)
|
704
757
|
yield result, response if block_given?
|
705
758
|
return result
|
706
759
|
end
|