google-cloud-compute-v1 2.2.0 → 2.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -78,6 +78,44 @@ module Google
78
78
  result
79
79
  end
80
80
 
81
+ ##
82
+ # Baseline implementation for the bulk_insert REST call
83
+ #
84
+ # @param request_pb [::Google::Cloud::Compute::V1::BulkInsertRegionDiskRequest]
85
+ # A request object representing the call parameters. Required.
86
+ # @param options [::Gapic::CallOptions]
87
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
88
+ #
89
+ # @yield [result, operation] Access the result along with the TransportOperation object
90
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
91
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
92
+ #
93
+ # @return [::Google::Cloud::Compute::V1::Operation]
94
+ # A result object deserialized from the server's reply
95
+ def bulk_insert request_pb, options = nil
96
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
97
+
98
+ verb, uri, query_string_params, body = ServiceStub.transcode_bulk_insert_request request_pb
99
+ query_string_params = if query_string_params.any?
100
+ query_string_params.to_h { |p| p.split "=", 2 }
101
+ else
102
+ {}
103
+ end
104
+
105
+ response = @client_stub.make_http_request(
106
+ verb,
107
+ uri: uri,
108
+ body: body || "",
109
+ params: query_string_params,
110
+ options: options
111
+ )
112
+ operation = ::Gapic::Rest::TransportOperation.new response
113
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
114
+
115
+ yield result, operation if block_given?
116
+ result
117
+ end
118
+
81
119
  ##
82
120
  # Baseline implementation for the create_snapshot REST call
83
121
  #
@@ -458,6 +496,120 @@ module Google
458
496
  result
459
497
  end
460
498
 
499
+ ##
500
+ # Baseline implementation for the start_async_replication REST call
501
+ #
502
+ # @param request_pb [::Google::Cloud::Compute::V1::StartAsyncReplicationRegionDiskRequest]
503
+ # A request object representing the call parameters. Required.
504
+ # @param options [::Gapic::CallOptions]
505
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
506
+ #
507
+ # @yield [result, operation] Access the result along with the TransportOperation object
508
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
509
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
510
+ #
511
+ # @return [::Google::Cloud::Compute::V1::Operation]
512
+ # A result object deserialized from the server's reply
513
+ def start_async_replication request_pb, options = nil
514
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
515
+
516
+ verb, uri, query_string_params, body = ServiceStub.transcode_start_async_replication_request request_pb
517
+ query_string_params = if query_string_params.any?
518
+ query_string_params.to_h { |p| p.split "=", 2 }
519
+ else
520
+ {}
521
+ end
522
+
523
+ response = @client_stub.make_http_request(
524
+ verb,
525
+ uri: uri,
526
+ body: body || "",
527
+ params: query_string_params,
528
+ options: options
529
+ )
530
+ operation = ::Gapic::Rest::TransportOperation.new response
531
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
532
+
533
+ yield result, operation if block_given?
534
+ result
535
+ end
536
+
537
+ ##
538
+ # Baseline implementation for the stop_async_replication REST call
539
+ #
540
+ # @param request_pb [::Google::Cloud::Compute::V1::StopAsyncReplicationRegionDiskRequest]
541
+ # A request object representing the call parameters. Required.
542
+ # @param options [::Gapic::CallOptions]
543
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
544
+ #
545
+ # @yield [result, operation] Access the result along with the TransportOperation object
546
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
547
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
548
+ #
549
+ # @return [::Google::Cloud::Compute::V1::Operation]
550
+ # A result object deserialized from the server's reply
551
+ def stop_async_replication request_pb, options = nil
552
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
553
+
554
+ verb, uri, query_string_params, body = ServiceStub.transcode_stop_async_replication_request request_pb
555
+ query_string_params = if query_string_params.any?
556
+ query_string_params.to_h { |p| p.split "=", 2 }
557
+ else
558
+ {}
559
+ end
560
+
561
+ response = @client_stub.make_http_request(
562
+ verb,
563
+ uri: uri,
564
+ body: body || "",
565
+ params: query_string_params,
566
+ options: options
567
+ )
568
+ operation = ::Gapic::Rest::TransportOperation.new response
569
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
570
+
571
+ yield result, operation if block_given?
572
+ result
573
+ end
574
+
575
+ ##
576
+ # Baseline implementation for the stop_group_async_replication REST call
577
+ #
578
+ # @param request_pb [::Google::Cloud::Compute::V1::StopGroupAsyncReplicationRegionDiskRequest]
579
+ # A request object representing the call parameters. Required.
580
+ # @param options [::Gapic::CallOptions]
581
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
582
+ #
583
+ # @yield [result, operation] Access the result along with the TransportOperation object
584
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
585
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
586
+ #
587
+ # @return [::Google::Cloud::Compute::V1::Operation]
588
+ # A result object deserialized from the server's reply
589
+ def stop_group_async_replication request_pb, options = nil
590
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
591
+
592
+ verb, uri, query_string_params, body = ServiceStub.transcode_stop_group_async_replication_request request_pb
593
+ query_string_params = if query_string_params.any?
594
+ query_string_params.to_h { |p| p.split "=", 2 }
595
+ else
596
+ {}
597
+ end
598
+
599
+ response = @client_stub.make_http_request(
600
+ verb,
601
+ uri: uri,
602
+ body: body || "",
603
+ params: query_string_params,
604
+ options: options
605
+ )
606
+ operation = ::Gapic::Rest::TransportOperation.new response
607
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
608
+
609
+ yield result, operation if block_given?
610
+ result
611
+ end
612
+
461
613
  ##
462
614
  # Baseline implementation for the test_iam_permissions REST call
463
615
  #
@@ -558,6 +710,29 @@ module Google
558
710
  transcoder.transcode request_pb
559
711
  end
560
712
 
713
+ ##
714
+ # @private
715
+ #
716
+ # GRPC transcoding helper method for the bulk_insert REST call
717
+ #
718
+ # @param request_pb [::Google::Cloud::Compute::V1::BulkInsertRegionDiskRequest]
719
+ # A request object representing the call parameters. Required.
720
+ # @return [Array(String, [String, nil], Hash{String => String})]
721
+ # Uri, Body, Query string parameters
722
+ def self.transcode_bulk_insert_request request_pb
723
+ transcoder = Gapic::Rest::GrpcTranscoder.new
724
+ .with_bindings(
725
+ uri_method: :post,
726
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/disks/bulkInsert",
727
+ body: "bulk_insert_disk_resource_resource",
728
+ matches: [
729
+ ["project", %r{^[^/]+/?$}, false],
730
+ ["region", %r{^[^/]+/?$}, false]
731
+ ]
732
+ )
733
+ transcoder.transcode request_pb
734
+ end
735
+
561
736
  ##
562
737
  # @private
563
738
  #
@@ -792,6 +967,76 @@ module Google
792
967
  transcoder.transcode request_pb
793
968
  end
794
969
 
970
+ ##
971
+ # @private
972
+ #
973
+ # GRPC transcoding helper method for the start_async_replication REST call
974
+ #
975
+ # @param request_pb [::Google::Cloud::Compute::V1::StartAsyncReplicationRegionDiskRequest]
976
+ # A request object representing the call parameters. Required.
977
+ # @return [Array(String, [String, nil], Hash{String => String})]
978
+ # Uri, Body, Query string parameters
979
+ def self.transcode_start_async_replication_request request_pb
980
+ transcoder = Gapic::Rest::GrpcTranscoder.new
981
+ .with_bindings(
982
+ uri_method: :post,
983
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/disks/{disk}/startAsyncReplication",
984
+ body: "region_disks_start_async_replication_request_resource",
985
+ matches: [
986
+ ["project", %r{^[^/]+/?$}, false],
987
+ ["region", %r{^[^/]+/?$}, false],
988
+ ["disk", %r{^[^/]+/?$}, false]
989
+ ]
990
+ )
991
+ transcoder.transcode request_pb
992
+ end
993
+
994
+ ##
995
+ # @private
996
+ #
997
+ # GRPC transcoding helper method for the stop_async_replication REST call
998
+ #
999
+ # @param request_pb [::Google::Cloud::Compute::V1::StopAsyncReplicationRegionDiskRequest]
1000
+ # A request object representing the call parameters. Required.
1001
+ # @return [Array(String, [String, nil], Hash{String => String})]
1002
+ # Uri, Body, Query string parameters
1003
+ def self.transcode_stop_async_replication_request request_pb
1004
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1005
+ .with_bindings(
1006
+ uri_method: :post,
1007
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/disks/{disk}/stopAsyncReplication",
1008
+ matches: [
1009
+ ["project", %r{^[^/]+/?$}, false],
1010
+ ["region", %r{^[^/]+/?$}, false],
1011
+ ["disk", %r{^[^/]+/?$}, false]
1012
+ ]
1013
+ )
1014
+ transcoder.transcode request_pb
1015
+ end
1016
+
1017
+ ##
1018
+ # @private
1019
+ #
1020
+ # GRPC transcoding helper method for the stop_group_async_replication REST call
1021
+ #
1022
+ # @param request_pb [::Google::Cloud::Compute::V1::StopGroupAsyncReplicationRegionDiskRequest]
1023
+ # A request object representing the call parameters. Required.
1024
+ # @return [Array(String, [String, nil], Hash{String => String})]
1025
+ # Uri, Body, Query string parameters
1026
+ def self.transcode_stop_group_async_replication_request request_pb
1027
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1028
+ .with_bindings(
1029
+ uri_method: :post,
1030
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/disks/stopGroupAsyncReplication",
1031
+ body: "disks_stop_group_async_replication_resource_resource",
1032
+ matches: [
1033
+ ["project", %r{^[^/]+/?$}, false],
1034
+ ["region", %r{^[^/]+/?$}, false]
1035
+ ]
1036
+ )
1037
+ transcoder.transcode request_pb
1038
+ end
1039
+
795
1040
  ##
796
1041
  # @private
797
1042
  #
@@ -42,6 +42,7 @@ require "google/cloud/compute/v1/instance_templates/rest"
42
42
  require "google/cloud/compute/v1/instances/rest"
43
43
  require "google/cloud/compute/v1/interconnect_attachments/rest"
44
44
  require "google/cloud/compute/v1/interconnect_locations/rest"
45
+ require "google/cloud/compute/v1/interconnect_remote_locations/rest"
45
46
  require "google/cloud/compute/v1/interconnects/rest"
46
47
  require "google/cloud/compute/v1/license_codes/rest"
47
48
  require "google/cloud/compute/v1/licenses/rest"
@@ -413,7 +413,7 @@ module Google
413
413
  # @param options [::Gapic::CallOptions, ::Hash]
414
414
  # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
415
415
  #
416
- # @overload get_nat_mapping_info(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil, router: nil)
416
+ # @overload get_nat_mapping_info(filter: nil, max_results: nil, nat_name: nil, order_by: nil, page_token: nil, project: nil, region: nil, return_partial_success: nil, router: nil)
417
417
  # Pass arguments to `get_nat_mapping_info` via keyword arguments. Note that at
418
418
  # least one keyword argument is required. To specify no parameters, or to keep all
419
419
  # the default parameter values, pass an empty Hash as a request object (see above).
@@ -422,6 +422,8 @@ module Google
422
422
  # A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your 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) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`.
423
423
  # @param max_results [::Integer]
424
424
  # 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`)
425
+ # @param nat_name [::String]
426
+ # Name of the nat service to filter the Nat Mapping information. If it is omitted, all nats for this router will be returned. Name should conform to RFC1035.
425
427
  # @param order_by [::String]
426
428
  # Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using `orderBy="creationTimestamp desc"`. This sorts results based on the `creationTimestamp` field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by `name` or `creationTimestamp desc` is supported.
427
429
  # @param page_token [::String]
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Compute
23
23
  module V1
24
- VERSION = "2.2.0"
24
+ VERSION = "2.3.0"
25
25
  end
26
26
  end
27
27
  end
@@ -42,6 +42,7 @@ require "google/cloud/compute/v1/instance_templates"
42
42
  require "google/cloud/compute/v1/instances"
43
43
  require "google/cloud/compute/v1/interconnect_attachments"
44
44
  require "google/cloud/compute/v1/interconnect_locations"
45
+ require "google/cloud/compute/v1/interconnect_remote_locations"
45
46
  require "google/cloud/compute/v1/interconnects"
46
47
  require "google/cloud/compute/v1/license_codes"
47
48
  require "google/cloud/compute/v1/licenses"