google-cloud-compute-v1 0.5.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +1 -1
  3. data/AUTHENTICATION.md +7 -25
  4. data/README.md +4 -4
  5. data/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +2 -2
  6. data/lib/google/cloud/compute/v1/addresses/rest/client.rb +37 -8
  7. data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +59 -14
  8. data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +158 -19
  9. data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +46 -0
  10. data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +169 -23
  11. data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +46 -0
  12. data/lib/google/cloud/compute/v1/compute_pb.rb +534 -2
  13. data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +2 -2
  14. data/lib/google/cloud/compute/v1/disks/rest/client.rb +93 -24
  15. data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +44 -10
  16. data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +98 -31
  17. data/lib/google/cloud/compute/v1/firewall_policies/rest/service_stub.rb +2 -2
  18. data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +54 -13
  19. data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +70 -17
  20. data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +34 -7
  21. data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +64 -16
  22. data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +55 -14
  23. data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +2 -2
  24. data/lib/google/cloud/compute/v1/global_operations/rest/nonstandard_lro.rb +68 -0
  25. data/lib/google/cloud/compute/v1/global_operations.rb +1 -0
  26. data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +1 -1
  27. data/lib/google/cloud/compute/v1/global_organization_operations/rest/nonstandard_lro.rb +68 -0
  28. data/lib/google/cloud/compute/v1/global_organization_operations.rb +1 -0
  29. data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +47 -13
  30. data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +55 -14
  31. data/lib/google/cloud/compute/v1/images/rest/client.rb +64 -16
  32. data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +172 -47
  33. data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +71 -18
  34. data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +34 -7
  35. data/lib/google/cloud/compute/v1/instances/rest/client.rb +521 -96
  36. data/lib/google/cloud/compute/v1/instances/rest/service_stub.rb +91 -0
  37. data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +48 -11
  38. data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +1 -1
  39. data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +44 -10
  40. data/lib/google/cloud/compute/v1/licenses/rest/client.rb +34 -7
  41. data/lib/google/cloud/compute/v1/machine_images/credentials.rb +52 -0
  42. data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +804 -0
  43. data/lib/google/cloud/compute/v1/machine_images/rest/service_stub.rb +363 -0
  44. data/lib/google/cloud/compute/v1/machine_images/rest.rb +33 -0
  45. data/lib/google/cloud/compute/v1/machine_images.rb +44 -0
  46. data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +2 -2
  47. data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +60 -15
  48. data/lib/google/cloud/compute/v1/networks/rest/client.rb +85 -23
  49. data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +82 -21
  50. data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +37 -8
  51. data/lib/google/cloud/compute/v1/node_types/rest/client.rb +2 -2
  52. data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +48 -11
  53. data/lib/google/cloud/compute/v1/projects/rest/client.rb +107 -31
  54. data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +47 -13
  55. data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +51 -14
  56. data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +58 -13
  57. data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +58 -13
  58. data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +116 -5
  59. data/lib/google/cloud/compute/v1/region_commitments/rest/service_stub.rb +48 -0
  60. data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +1 -1
  61. data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +92 -23
  62. data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +47 -10
  63. data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +58 -13
  64. data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +171 -46
  65. data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +26 -5
  66. data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +24 -3
  67. data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +36 -7
  68. data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +38 -9
  69. data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +1 -1
  70. data/lib/google/cloud/compute/v1/region_operations/rest/nonstandard_lro.rb +68 -0
  71. data/lib/google/cloud/compute/v1/region_operations.rb +1 -0
  72. data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +38 -9
  73. data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +47 -10
  74. data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +62 -17
  75. data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +58 -13
  76. data/lib/google/cloud/compute/v1/regions/rest/client.rb +3 -3
  77. data/lib/google/cloud/compute/v1/reservations/rest/client.rb +138 -11
  78. data/lib/google/cloud/compute/v1/reservations/rest/service_stub.rb +48 -0
  79. data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +37 -8
  80. data/lib/google/cloud/compute/v1/routers/rest/client.rb +60 -15
  81. data/lib/google/cloud/compute/v1/routes/rest/client.rb +34 -7
  82. data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +75 -20
  83. data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +51 -14
  84. data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +116 -7
  85. data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +46 -0
  86. data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +37 -10
  87. data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +45 -11
  88. data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +71 -18
  89. data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +47 -13
  90. data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +56 -15
  91. data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +86 -24
  92. data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +37 -8
  93. data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +92 -23
  94. data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +74 -19
  95. data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +54 -13
  96. data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +37 -8
  97. data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +65 -17
  98. data/lib/google/cloud/compute/v1/version.rb +1 -1
  99. data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +48 -11
  100. data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +37 -8
  101. data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +1 -1
  102. data/lib/google/cloud/compute/v1/zone_operations/rest/nonstandard_lro.rb +68 -0
  103. data/lib/google/cloud/compute/v1/zone_operations.rb +1 -0
  104. data/lib/google/cloud/compute/v1/zones/rest/client.rb +1 -1
  105. data/lib/google/cloud/compute/v1.rb +3 -0
  106. data/proto_docs/README.md +1 -1
  107. data/proto_docs/google/api/resource.rb +10 -71
  108. data/proto_docs/google/cloud/compute/v1/compute.rb +1647 -330
  109. metadata +14 -7
@@ -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::Rest::BaseOperation]
204
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
192
205
  # @yieldparam response [::Faraday::Response]
193
206
  #
194
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
277
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
258
278
  # @yieldparam response [::Faraday::Response]
259
279
  #
260
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
476
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
450
477
  # @yieldparam response [::Faraday::Response]
451
478
  #
452
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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
@@ -506,7 +540,7 @@ module Google
506
540
  # the default parameter values, pass an empty Hash as a request object (see above).
507
541
  #
508
542
  # @param filter [::String]
509
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
543
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
510
544
  # @param max_results [::Integer]
511
545
  # The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
512
546
  # @param order_by [::String]
@@ -581,7 +615,7 @@ module Google
581
615
  # The direction of the exchanged routes.
582
616
  # Check the Direction enum for the list of possible values.
583
617
  # @param filter [::String]
584
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
618
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
585
619
  # @param max_results [::Integer]
586
620
  # The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
587
621
  # @param network [::String]
@@ -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::Rest::BaseOperation]
704
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
671
705
  # @yieldparam response [::Faraday::Response]
672
706
  #
673
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
779
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
739
780
  # @yieldparam response [::Faraday::Response]
740
781
  #
741
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
852
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
805
853
  # @yieldparam response [::Faraday::Response]
806
854
  #
807
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
927
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
873
928
  # @yieldparam response [::Faraday::Response]
874
929
  #
875
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
210
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
198
211
  # @yieldparam response [::Faraday::Response]
199
212
  #
200
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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
@@ -254,7 +275,7 @@ module Google
254
275
  # the default parameter values, pass an empty Hash as a request object (see above).
255
276
  #
256
277
  # @param filter [::String]
257
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
278
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
258
279
  # @param include_all_scopes [::Boolean]
259
280
  # Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.
260
281
  # @param max_results [::Integer]
@@ -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::Rest::BaseOperation]
360
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
340
361
  # @yieldparam response [::Faraday::Response]
341
362
  #
342
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
438
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
410
439
  # @yieldparam response [::Faraday::Response]
411
440
  #
412
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
648
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
612
649
  # @yieldparam response [::Faraday::Response]
613
650
  #
614
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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
@@ -668,7 +713,7 @@ module Google
668
713
  # the default parameter values, pass an empty Hash as a request object (see above).
669
714
  #
670
715
  # @param filter [::String]
671
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
716
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
672
717
  # @param max_results [::Integer]
673
718
  # The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
674
719
  # @param order_by [::String]
@@ -742,7 +787,7 @@ module Google
742
787
  # the default parameter values, pass an empty Hash as a request object (see above).
743
788
  #
744
789
  # @param filter [::String]
745
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
790
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
746
791
  # @param max_results [::Integer]
747
792
  # The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
748
793
  # @param node_group [::String]
@@ -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::Rest::BaseOperation]
876
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
832
877
  # @yieldparam response [::Faraday::Response]
833
878
  #
834
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
1021
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
969
1022
  # @yieldparam response [::Faraday::Response]
970
1023
  #
971
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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
  ##
@@ -174,7 +187,7 @@ module Google
174
187
  # the default parameter values, pass an empty Hash as a request object (see above).
175
188
  #
176
189
  # @param filter [::String]
177
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
190
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
178
191
  # @param include_all_scopes [::Boolean]
179
192
  # Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.
180
193
  # @param max_results [::Integer]
@@ -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::Rest::BaseOperation]
272
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
260
273
  # @yieldparam response [::Faraday::Response]
261
274
  #
262
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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::Rest::BaseOperation]
480
+ # @yieldparam result [::Gapic::GenericLRO::Operation]
460
481
  # @yieldparam response [::Faraday::Response]
461
482
  #
462
- # @return [::Gapic::Rest::BaseOperation]
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 = ::Gapic::Rest::BaseOperation.new 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
@@ -516,7 +545,7 @@ module Google
516
545
  # the default parameter values, pass an empty Hash as a request object (see above).
517
546
  #
518
547
  # @param filter [::String]
519
- # A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either `=`, `!=`, `>`, or `<`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
548
+ # A filter expression that filters resources listed in the response. The expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ```
520
549
  # @param max_results [::Integer]
521
550
  # The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
522
551
  # @param order_by [::String]