google-cloud-compute-v1 2.17.0 → 2.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -153,6 +153,46 @@ module Google
153
153
  end
154
154
  end
155
155
 
156
+ ##
157
+ # Baseline implementation for the delete_route_policy REST call
158
+ #
159
+ # @param request_pb [::Google::Cloud::Compute::V1::DeleteRoutePolicyRouterRequest]
160
+ # A request object representing the call parameters. Required.
161
+ # @param options [::Gapic::CallOptions]
162
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
163
+ #
164
+ # @yield [result, operation] Access the result along with the TransportOperation object
165
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
166
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
167
+ #
168
+ # @return [::Google::Cloud::Compute::V1::Operation]
169
+ # A result object deserialized from the server's reply
170
+ def delete_route_policy request_pb, options = nil
171
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
172
+
173
+ verb, uri, query_string_params, body = ServiceStub.transcode_delete_route_policy_request request_pb
174
+ query_string_params = if query_string_params.any?
175
+ query_string_params.to_h { |p| p.split "=", 2 }
176
+ else
177
+ {}
178
+ end
179
+
180
+ response = @client_stub.make_http_request(
181
+ verb,
182
+ uri: uri,
183
+ body: body || "",
184
+ params: query_string_params,
185
+ method_name: "delete_route_policy",
186
+ options: options
187
+ )
188
+ operation = ::Gapic::Rest::TransportOperation.new response
189
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
190
+ catch :response do
191
+ yield result, operation if block_given?
192
+ result
193
+ end
194
+ end
195
+
156
196
  ##
157
197
  # Baseline implementation for the get REST call
158
198
  #
@@ -273,6 +313,46 @@ module Google
273
313
  end
274
314
  end
275
315
 
316
+ ##
317
+ # Baseline implementation for the get_route_policy REST call
318
+ #
319
+ # @param request_pb [::Google::Cloud::Compute::V1::GetRoutePolicyRouterRequest]
320
+ # A request object representing the call parameters. Required.
321
+ # @param options [::Gapic::CallOptions]
322
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
323
+ #
324
+ # @yield [result, operation] Access the result along with the TransportOperation object
325
+ # @yieldparam result [::Google::Cloud::Compute::V1::RoutersGetRoutePolicyResponse]
326
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
327
+ #
328
+ # @return [::Google::Cloud::Compute::V1::RoutersGetRoutePolicyResponse]
329
+ # A result object deserialized from the server's reply
330
+ def get_route_policy request_pb, options = nil
331
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
332
+
333
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_route_policy_request request_pb
334
+ query_string_params = if query_string_params.any?
335
+ query_string_params.to_h { |p| p.split "=", 2 }
336
+ else
337
+ {}
338
+ end
339
+
340
+ response = @client_stub.make_http_request(
341
+ verb,
342
+ uri: uri,
343
+ body: body || "",
344
+ params: query_string_params,
345
+ method_name: "get_route_policy",
346
+ options: options
347
+ )
348
+ operation = ::Gapic::Rest::TransportOperation.new response
349
+ result = ::Google::Cloud::Compute::V1::RoutersGetRoutePolicyResponse.decode_json response.body, ignore_unknown_fields: true
350
+ catch :response do
351
+ yield result, operation if block_given?
352
+ result
353
+ end
354
+ end
355
+
276
356
  ##
277
357
  # Baseline implementation for the get_router_status REST call
278
358
  #
@@ -393,6 +473,86 @@ module Google
393
473
  end
394
474
  end
395
475
 
476
+ ##
477
+ # Baseline implementation for the list_bgp_routes REST call
478
+ #
479
+ # @param request_pb [::Google::Cloud::Compute::V1::ListBgpRoutesRoutersRequest]
480
+ # A request object representing the call parameters. Required.
481
+ # @param options [::Gapic::CallOptions]
482
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
483
+ #
484
+ # @yield [result, operation] Access the result along with the TransportOperation object
485
+ # @yieldparam result [::Google::Cloud::Compute::V1::RoutersListBgpRoutes]
486
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
487
+ #
488
+ # @return [::Google::Cloud::Compute::V1::RoutersListBgpRoutes]
489
+ # A result object deserialized from the server's reply
490
+ def list_bgp_routes request_pb, options = nil
491
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
492
+
493
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_bgp_routes_request request_pb
494
+ query_string_params = if query_string_params.any?
495
+ query_string_params.to_h { |p| p.split "=", 2 }
496
+ else
497
+ {}
498
+ end
499
+
500
+ response = @client_stub.make_http_request(
501
+ verb,
502
+ uri: uri,
503
+ body: body || "",
504
+ params: query_string_params,
505
+ method_name: "list_bgp_routes",
506
+ options: options
507
+ )
508
+ operation = ::Gapic::Rest::TransportOperation.new response
509
+ result = ::Google::Cloud::Compute::V1::RoutersListBgpRoutes.decode_json response.body, ignore_unknown_fields: true
510
+ catch :response do
511
+ yield result, operation if block_given?
512
+ result
513
+ end
514
+ end
515
+
516
+ ##
517
+ # Baseline implementation for the list_route_policies REST call
518
+ #
519
+ # @param request_pb [::Google::Cloud::Compute::V1::ListRoutePoliciesRoutersRequest]
520
+ # A request object representing the call parameters. Required.
521
+ # @param options [::Gapic::CallOptions]
522
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
523
+ #
524
+ # @yield [result, operation] Access the result along with the TransportOperation object
525
+ # @yieldparam result [::Google::Cloud::Compute::V1::RoutersListRoutePolicies]
526
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
527
+ #
528
+ # @return [::Google::Cloud::Compute::V1::RoutersListRoutePolicies]
529
+ # A result object deserialized from the server's reply
530
+ def list_route_policies request_pb, options = nil
531
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
532
+
533
+ verb, uri, query_string_params, body = ServiceStub.transcode_list_route_policies_request request_pb
534
+ query_string_params = if query_string_params.any?
535
+ query_string_params.to_h { |p| p.split "=", 2 }
536
+ else
537
+ {}
538
+ end
539
+
540
+ response = @client_stub.make_http_request(
541
+ verb,
542
+ uri: uri,
543
+ body: body || "",
544
+ params: query_string_params,
545
+ method_name: "list_route_policies",
546
+ options: options
547
+ )
548
+ operation = ::Gapic::Rest::TransportOperation.new response
549
+ result = ::Google::Cloud::Compute::V1::RoutersListRoutePolicies.decode_json response.body, ignore_unknown_fields: true
550
+ catch :response do
551
+ yield result, operation if block_given?
552
+ result
553
+ end
554
+ end
555
+
396
556
  ##
397
557
  # Baseline implementation for the patch REST call
398
558
  #
@@ -433,6 +593,46 @@ module Google
433
593
  end
434
594
  end
435
595
 
596
+ ##
597
+ # Baseline implementation for the patch_route_policy REST call
598
+ #
599
+ # @param request_pb [::Google::Cloud::Compute::V1::PatchRoutePolicyRouterRequest]
600
+ # A request object representing the call parameters. Required.
601
+ # @param options [::Gapic::CallOptions]
602
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
603
+ #
604
+ # @yield [result, operation] Access the result along with the TransportOperation object
605
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
606
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
607
+ #
608
+ # @return [::Google::Cloud::Compute::V1::Operation]
609
+ # A result object deserialized from the server's reply
610
+ def patch_route_policy request_pb, options = nil
611
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
612
+
613
+ verb, uri, query_string_params, body = ServiceStub.transcode_patch_route_policy_request request_pb
614
+ query_string_params = if query_string_params.any?
615
+ query_string_params.to_h { |p| p.split "=", 2 }
616
+ else
617
+ {}
618
+ end
619
+
620
+ response = @client_stub.make_http_request(
621
+ verb,
622
+ uri: uri,
623
+ body: body || "",
624
+ params: query_string_params,
625
+ method_name: "patch_route_policy",
626
+ options: options
627
+ )
628
+ operation = ::Gapic::Rest::TransportOperation.new response
629
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
630
+ catch :response do
631
+ yield result, operation if block_given?
632
+ result
633
+ end
634
+ end
635
+
436
636
  ##
437
637
  # Baseline implementation for the preview REST call
438
638
  #
@@ -513,6 +713,46 @@ module Google
513
713
  end
514
714
  end
515
715
 
716
+ ##
717
+ # Baseline implementation for the update_route_policy REST call
718
+ #
719
+ # @param request_pb [::Google::Cloud::Compute::V1::UpdateRoutePolicyRouterRequest]
720
+ # A request object representing the call parameters. Required.
721
+ # @param options [::Gapic::CallOptions]
722
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
723
+ #
724
+ # @yield [result, operation] Access the result along with the TransportOperation object
725
+ # @yieldparam result [::Google::Cloud::Compute::V1::Operation]
726
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
727
+ #
728
+ # @return [::Google::Cloud::Compute::V1::Operation]
729
+ # A result object deserialized from the server's reply
730
+ def update_route_policy request_pb, options = nil
731
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
732
+
733
+ verb, uri, query_string_params, body = ServiceStub.transcode_update_route_policy_request request_pb
734
+ query_string_params = if query_string_params.any?
735
+ query_string_params.to_h { |p| p.split "=", 2 }
736
+ else
737
+ {}
738
+ end
739
+
740
+ response = @client_stub.make_http_request(
741
+ verb,
742
+ uri: uri,
743
+ body: body || "",
744
+ params: query_string_params,
745
+ method_name: "update_route_policy",
746
+ options: options
747
+ )
748
+ operation = ::Gapic::Rest::TransportOperation.new response
749
+ result = ::Google::Cloud::Compute::V1::Operation.decode_json response.body, ignore_unknown_fields: true
750
+ catch :response do
751
+ yield result, operation if block_given?
752
+ result
753
+ end
754
+ end
755
+
516
756
  ##
517
757
  # @private
518
758
  #
@@ -557,6 +797,29 @@ module Google
557
797
  transcoder.transcode request_pb
558
798
  end
559
799
 
800
+ ##
801
+ # @private
802
+ #
803
+ # GRPC transcoding helper method for the delete_route_policy REST call
804
+ #
805
+ # @param request_pb [::Google::Cloud::Compute::V1::DeleteRoutePolicyRouterRequest]
806
+ # A request object representing the call parameters. Required.
807
+ # @return [Array(String, [String, nil], Hash{String => String})]
808
+ # Uri, Body, Query string parameters
809
+ def self.transcode_delete_route_policy_request request_pb
810
+ transcoder = Gapic::Rest::GrpcTranscoder.new
811
+ .with_bindings(
812
+ uri_method: :post,
813
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/deleteRoutePolicy",
814
+ matches: [
815
+ ["project", %r{^[^/]+/?$}, false],
816
+ ["region", %r{^[^/]+/?$}, false],
817
+ ["router", %r{^[^/]+/?$}, false]
818
+ ]
819
+ )
820
+ transcoder.transcode request_pb
821
+ end
822
+
560
823
  ##
561
824
  # @private
562
825
  #
@@ -626,6 +889,29 @@ module Google
626
889
  transcoder.transcode request_pb
627
890
  end
628
891
 
892
+ ##
893
+ # @private
894
+ #
895
+ # GRPC transcoding helper method for the get_route_policy REST call
896
+ #
897
+ # @param request_pb [::Google::Cloud::Compute::V1::GetRoutePolicyRouterRequest]
898
+ # A request object representing the call parameters. Required.
899
+ # @return [Array(String, [String, nil], Hash{String => String})]
900
+ # Uri, Body, Query string parameters
901
+ def self.transcode_get_route_policy_request request_pb
902
+ transcoder = Gapic::Rest::GrpcTranscoder.new
903
+ .with_bindings(
904
+ uri_method: :get,
905
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/getRoutePolicy",
906
+ matches: [
907
+ ["project", %r{^[^/]+/?$}, false],
908
+ ["region", %r{^[^/]+/?$}, false],
909
+ ["router", %r{^[^/]+/?$}, false]
910
+ ]
911
+ )
912
+ transcoder.transcode request_pb
913
+ end
914
+
629
915
  ##
630
916
  # @private
631
917
  #
@@ -694,6 +980,52 @@ module Google
694
980
  transcoder.transcode request_pb
695
981
  end
696
982
 
983
+ ##
984
+ # @private
985
+ #
986
+ # GRPC transcoding helper method for the list_bgp_routes REST call
987
+ #
988
+ # @param request_pb [::Google::Cloud::Compute::V1::ListBgpRoutesRoutersRequest]
989
+ # A request object representing the call parameters. Required.
990
+ # @return [Array(String, [String, nil], Hash{String => String})]
991
+ # Uri, Body, Query string parameters
992
+ def self.transcode_list_bgp_routes_request request_pb
993
+ transcoder = Gapic::Rest::GrpcTranscoder.new
994
+ .with_bindings(
995
+ uri_method: :get,
996
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/listBgpRoutes",
997
+ matches: [
998
+ ["project", %r{^[^/]+/?$}, false],
999
+ ["region", %r{^[^/]+/?$}, false],
1000
+ ["router", %r{^[^/]+/?$}, false]
1001
+ ]
1002
+ )
1003
+ transcoder.transcode request_pb
1004
+ end
1005
+
1006
+ ##
1007
+ # @private
1008
+ #
1009
+ # GRPC transcoding helper method for the list_route_policies REST call
1010
+ #
1011
+ # @param request_pb [::Google::Cloud::Compute::V1::ListRoutePoliciesRoutersRequest]
1012
+ # A request object representing the call parameters. Required.
1013
+ # @return [Array(String, [String, nil], Hash{String => String})]
1014
+ # Uri, Body, Query string parameters
1015
+ def self.transcode_list_route_policies_request request_pb
1016
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1017
+ .with_bindings(
1018
+ uri_method: :get,
1019
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/listRoutePolicies",
1020
+ matches: [
1021
+ ["project", %r{^[^/]+/?$}, false],
1022
+ ["region", %r{^[^/]+/?$}, false],
1023
+ ["router", %r{^[^/]+/?$}, false]
1024
+ ]
1025
+ )
1026
+ transcoder.transcode request_pb
1027
+ end
1028
+
697
1029
  ##
698
1030
  # @private
699
1031
  #
@@ -718,6 +1050,30 @@ module Google
718
1050
  transcoder.transcode request_pb
719
1051
  end
720
1052
 
1053
+ ##
1054
+ # @private
1055
+ #
1056
+ # GRPC transcoding helper method for the patch_route_policy REST call
1057
+ #
1058
+ # @param request_pb [::Google::Cloud::Compute::V1::PatchRoutePolicyRouterRequest]
1059
+ # A request object representing the call parameters. Required.
1060
+ # @return [Array(String, [String, nil], Hash{String => String})]
1061
+ # Uri, Body, Query string parameters
1062
+ def self.transcode_patch_route_policy_request request_pb
1063
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1064
+ .with_bindings(
1065
+ uri_method: :post,
1066
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/patchRoutePolicy",
1067
+ body: "route_policy_resource",
1068
+ matches: [
1069
+ ["project", %r{^[^/]+/?$}, false],
1070
+ ["region", %r{^[^/]+/?$}, false],
1071
+ ["router", %r{^[^/]+/?$}, false]
1072
+ ]
1073
+ )
1074
+ transcoder.transcode request_pb
1075
+ end
1076
+
721
1077
  ##
722
1078
  # @private
723
1079
  #
@@ -765,6 +1121,30 @@ module Google
765
1121
  )
766
1122
  transcoder.transcode request_pb
767
1123
  end
1124
+
1125
+ ##
1126
+ # @private
1127
+ #
1128
+ # GRPC transcoding helper method for the update_route_policy REST call
1129
+ #
1130
+ # @param request_pb [::Google::Cloud::Compute::V1::UpdateRoutePolicyRouterRequest]
1131
+ # A request object representing the call parameters. Required.
1132
+ # @return [Array(String, [String, nil], Hash{String => String})]
1133
+ # Uri, Body, Query string parameters
1134
+ def self.transcode_update_route_policy_request request_pb
1135
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1136
+ .with_bindings(
1137
+ uri_method: :post,
1138
+ uri_template: "/compute/v1/projects/{project}/regions/{region}/routers/{router}/updateRoutePolicy",
1139
+ body: "route_policy_resource",
1140
+ matches: [
1141
+ ["project", %r{^[^/]+/?$}, false],
1142
+ ["region", %r{^[^/]+/?$}, false],
1143
+ ["router", %r{^[^/]+/?$}, false]
1144
+ ]
1145
+ )
1146
+ transcoder.transcode request_pb
1147
+ end
768
1148
  end
769
1149
  end
770
1150
  end
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Compute
23
23
  module V1
24
- VERSION = "2.17.0"
24
+ VERSION = "2.18.0"
25
25
  end
26
26
  end
27
27
  end
@@ -221,6 +221,12 @@ module Google
221
221
  # Pythonic which are included in `protobuf>=5.29.x`. This feature will be
222
222
  # enabled by default 1 month after launching the feature in preview
223
223
  # packages.
224
+ # @!attribute [rw] unversioned_package_disabled
225
+ # @return [::Boolean]
226
+ # Disables generation of an unversioned Python package for this client
227
+ # library. This means that the module names will need to be versioned in
228
+ # import statements. For example `import google.cloud.library_v2` instead
229
+ # of `import google.cloud.library`.
224
230
  class ExperimentalFeatures
225
231
  include ::Google::Protobuf::MessageExts
226
232
  extend ::Google::Protobuf::MessageExts::ClassMethods