google-cloud-gke_backup-v1 0.4.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -19,6 +19,8 @@
19
19
  require "google/cloud/errors"
20
20
  require "google/cloud/gkebackup/v1/gkebackup_pb"
21
21
  require "google/cloud/gke_backup/v1/backup_for_gke/rest/service_stub"
22
+ require "google/cloud/location/rest"
23
+ require "google/iam/v1/rest"
22
24
 
23
25
  module Google
24
26
  module Cloud
@@ -221,6 +223,20 @@ module Google
221
223
  config.endpoint = @config.endpoint
222
224
  end
223
225
 
226
+ @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
227
+ config.credentials = credentials
228
+ config.quota_project = @quota_project_id
229
+ config.endpoint = @config.endpoint
230
+ config.bindings_override = @config.bindings_override
231
+ end
232
+
233
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
234
+ config.credentials = credentials
235
+ config.quota_project = @quota_project_id
236
+ config.endpoint = @config.endpoint
237
+ config.bindings_override = @config.bindings_override
238
+ end
239
+
224
240
  @backup_for_gke_stub = ::Google::Cloud::GkeBackup::V1::BackupForGKE::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
225
241
  end
226
242
 
@@ -231,6 +247,20 @@ module Google
231
247
  #
232
248
  attr_reader :operations_client
233
249
 
250
+ ##
251
+ # Get the associated client for mix-in of the Locations.
252
+ #
253
+ # @return [Google::Cloud::Location::Locations::Rest::Client]
254
+ #
255
+ attr_reader :location_client
256
+
257
+ ##
258
+ # Get the associated client for mix-in of the IAMPolicy.
259
+ #
260
+ # @return [Google::Iam::V1::IAMPolicy::Rest::Client]
261
+ #
262
+ attr_reader :iam_policy_client
263
+
234
264
  # Service calls
235
265
 
236
266
  ##
@@ -253,7 +283,7 @@ module Google
253
283
  #
254
284
  # @param parent [::String]
255
285
  # Required. The location within which to create the BackupPlan.
256
- # Format: projects/*/locations/*
286
+ # Format: `projects/*/locations/*`
257
287
  # @param backup_plan [::Google::Cloud::GkeBackup::V1::BackupPlan, ::Hash]
258
288
  # Required. The BackupPlan resource object to create.
259
289
  # @param backup_plan_id [::String]
@@ -328,7 +358,7 @@ module Google
328
358
  #
329
359
  # @param parent [::String]
330
360
  # Required. The location that contains the BackupPlans to list.
331
- # Format: projects/*/locations/*
361
+ # Format: `projects/*/locations/*`
332
362
  # @param page_size [::Integer]
333
363
  # The target number of results to return in a single response.
334
364
  # If not specified, a default value will be chosen by the service.
@@ -409,7 +439,7 @@ module Google
409
439
  #
410
440
  # @param name [::String]
411
441
  # Required. Fully qualified BackupPlan name.
412
- # Format: projects/*/locations/*/backupPlans/*
442
+ # Format: `projects/*/locations/*/backupPlans/*`
413
443
  # @yield [result, operation] Access the result along with the TransportOperation object
414
444
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::BackupPlan]
415
445
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -471,8 +501,8 @@ module Google
471
501
  # the default parameter values, pass an empty Hash as a request object (see above).
472
502
  #
473
503
  # @param backup_plan [::Google::Cloud::GkeBackup::V1::BackupPlan, ::Hash]
474
- # Required. A new version of the BackupPlan resource that contains updated fields.
475
- # This may be sparsely populated if an `update_mask` is provided.
504
+ # Required. A new version of the BackupPlan resource that contains updated
505
+ # fields. This may be sparsely populated if an `update_mask` is provided.
476
506
  # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
477
507
  # This is used to specify the fields to be overwritten in the
478
508
  # BackupPlan targeted for update. The values for each of these
@@ -546,11 +576,11 @@ module Google
546
576
  #
547
577
  # @param name [::String]
548
578
  # Required. Fully qualified BackupPlan name.
549
- # Format: projects/*/locations/*/backupPlans/*
579
+ # Format: `projects/*/locations/*/backupPlans/*`
550
580
  # @param etag [::String]
551
581
  # If provided, this value must match the current value of the
552
- # target BackupPlan's {::Google::Cloud::GkeBackup::V1::BackupPlan#etag etag} field or the request is
553
- # rejected.
582
+ # target BackupPlan's {::Google::Cloud::GkeBackup::V1::BackupPlan#etag etag} field
583
+ # or the request is rejected.
554
584
  # @yield [result, operation] Access the result along with the TransportOperation object
555
585
  # @yieldparam result [::Gapic::Operation]
556
586
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -614,18 +644,18 @@ module Google
614
644
  #
615
645
  # @param parent [::String]
616
646
  # Required. The BackupPlan within which to create the Backup.
617
- # Format: projects/*/locations/*/backupPlans/*
647
+ # Format: `projects/*/locations/*/backupPlans/*`
618
648
  # @param backup [::Google::Cloud::GkeBackup::V1::Backup, ::Hash]
619
649
  # The Backup resource to create.
620
650
  # @param backup_id [::String]
621
651
  # The client-provided short name for the Backup resource.
622
652
  # This name must:
623
653
  #
624
- # - be between 1 and 63 characters long (inclusive)
625
- # - consist of only lower-case ASCII letters, numbers, and dashes
626
- # - start with a lower-case letter
627
- # - end with a lower-case letter or number
628
- # - be unique within the set of Backups in this BackupPlan
654
+ # - be between 1 and 63 characters long (inclusive)
655
+ # - consist of only lower-case ASCII letters, numbers, and dashes
656
+ # - start with a lower-case letter
657
+ # - end with a lower-case letter or number
658
+ # - be unique within the set of Backups in this BackupPlan
629
659
  # @yield [result, operation] Access the result along with the TransportOperation object
630
660
  # @yieldparam result [::Gapic::Operation]
631
661
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -689,7 +719,7 @@ module Google
689
719
  #
690
720
  # @param parent [::String]
691
721
  # Required. The BackupPlan that contains the Backups to list.
692
- # Format: projects/*/locations/*/backupPlans/*
722
+ # Format: `projects/*/locations/*/backupPlans/*`
693
723
  # @param page_size [::Integer]
694
724
  # The target number of results to return in a single response.
695
725
  # If not specified, a default value will be chosen by the service.
@@ -771,7 +801,7 @@ module Google
771
801
  #
772
802
  # @param name [::String]
773
803
  # Required. Full name of the Backup resource.
774
- # Format: projects/*/locations/*/backupPlans/*/backups/*
804
+ # Format: `projects/*/locations/*/backupPlans/*/backups/*`
775
805
  # @yield [result, operation] Access the result along with the TransportOperation object
776
806
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::Backup]
777
807
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -833,8 +863,8 @@ module Google
833
863
  # the default parameter values, pass an empty Hash as a request object (see above).
834
864
  #
835
865
  # @param backup [::Google::Cloud::GkeBackup::V1::Backup, ::Hash]
836
- # Required. A new version of the Backup resource that contains updated fields.
837
- # This may be sparsely populated if an `update_mask` is provided.
866
+ # Required. A new version of the Backup resource that contains updated
867
+ # fields. This may be sparsely populated if an `update_mask` is provided.
838
868
  # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
839
869
  # This is used to specify the fields to be overwritten in the
840
870
  # Backup targeted for update. The values for each of these
@@ -907,11 +937,11 @@ module Google
907
937
  #
908
938
  # @param name [::String]
909
939
  # Required. Name of the Backup resource.
910
- # Format: projects/*/locations/*/backupPlans/*/backups/*
940
+ # Format: `projects/*/locations/*/backupPlans/*/backups/*`
911
941
  # @param etag [::String]
912
942
  # If provided, this value must match the current value of the
913
- # target Backup's {::Google::Cloud::GkeBackup::V1::Backup#etag etag} field or the request is
914
- # rejected.
943
+ # target Backup's {::Google::Cloud::GkeBackup::V1::Backup#etag etag} field or the
944
+ # request is rejected.
915
945
  # @param force [::Boolean]
916
946
  # If set to true, any VolumeBackups below this Backup will also be deleted.
917
947
  # Otherwise, the request will only succeed if the Backup has no
@@ -979,7 +1009,7 @@ module Google
979
1009
  #
980
1010
  # @param parent [::String]
981
1011
  # Required. The Backup that contains the VolumeBackups to list.
982
- # Format: projects/*/locations/*/backupPlans/*/backups/*
1012
+ # Format: `projects/*/locations/*/backupPlans/*/backups/*`
983
1013
  # @param page_size [::Integer]
984
1014
  # The target number of results to return in a single response.
985
1015
  # If not specified, a default value will be chosen by the service.
@@ -1061,7 +1091,7 @@ module Google
1061
1091
  #
1062
1092
  # @param name [::String]
1063
1093
  # Required. Full name of the VolumeBackup resource.
1064
- # Format: projects/*/locations/*/backupPlans/*/backups/*/volumeBackups/*
1094
+ # Format: `projects/*/locations/*/backupPlans/*/backups/*/volumeBackups/*`
1065
1095
  # @yield [result, operation] Access the result along with the TransportOperation object
1066
1096
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::VolumeBackup]
1067
1097
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -1124,18 +1154,18 @@ module Google
1124
1154
  #
1125
1155
  # @param parent [::String]
1126
1156
  # Required. The location within which to create the RestorePlan.
1127
- # Format: projects/*/locations/*
1157
+ # Format: `projects/*/locations/*`
1128
1158
  # @param restore_plan [::Google::Cloud::GkeBackup::V1::RestorePlan, ::Hash]
1129
1159
  # Required. The RestorePlan resource object to create.
1130
1160
  # @param restore_plan_id [::String]
1131
1161
  # Required. The client-provided short name for the RestorePlan resource.
1132
1162
  # This name must:
1133
1163
  #
1134
- # - be between 1 and 63 characters long (inclusive)
1135
- # - consist of only lower-case ASCII letters, numbers, and dashes
1136
- # - start with a lower-case letter
1137
- # - end with a lower-case letter or number
1138
- # - be unique within the set of RestorePlans in this location
1164
+ # - be between 1 and 63 characters long (inclusive)
1165
+ # - consist of only lower-case ASCII letters, numbers, and dashes
1166
+ # - start with a lower-case letter
1167
+ # - end with a lower-case letter or number
1168
+ # - be unique within the set of RestorePlans in this location
1139
1169
  # @yield [result, operation] Access the result along with the TransportOperation object
1140
1170
  # @yieldparam result [::Gapic::Operation]
1141
1171
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -1199,7 +1229,7 @@ module Google
1199
1229
  #
1200
1230
  # @param parent [::String]
1201
1231
  # Required. The location that contains the RestorePlans to list.
1202
- # Format: projects/*/locations/*
1232
+ # Format: `projects/*/locations/*`
1203
1233
  # @param page_size [::Integer]
1204
1234
  # The target number of results to return in a single response.
1205
1235
  # If not specified, a default value will be chosen by the service.
@@ -1280,7 +1310,7 @@ module Google
1280
1310
  #
1281
1311
  # @param name [::String]
1282
1312
  # Required. Fully qualified RestorePlan name.
1283
- # Format: projects/*/locations/*/restorePlans/*
1313
+ # Format: `projects/*/locations/*/restorePlans/*`
1284
1314
  # @yield [result, operation] Access the result along with the TransportOperation object
1285
1315
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::RestorePlan]
1286
1316
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -1342,8 +1372,8 @@ module Google
1342
1372
  # the default parameter values, pass an empty Hash as a request object (see above).
1343
1373
  #
1344
1374
  # @param restore_plan [::Google::Cloud::GkeBackup::V1::RestorePlan, ::Hash]
1345
- # Required. A new version of the RestorePlan resource that contains updated fields.
1346
- # This may be sparsely populated if an `update_mask` is provided.
1375
+ # Required. A new version of the RestorePlan resource that contains updated
1376
+ # fields. This may be sparsely populated if an `update_mask` is provided.
1347
1377
  # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1348
1378
  # This is used to specify the fields to be overwritten in the
1349
1379
  # RestorePlan targeted for update. The values for each of these
@@ -1416,11 +1446,11 @@ module Google
1416
1446
  #
1417
1447
  # @param name [::String]
1418
1448
  # Required. Fully qualified RestorePlan name.
1419
- # Format: projects/*/locations/*/restorePlans/*
1449
+ # Format: `projects/*/locations/*/restorePlans/*`
1420
1450
  # @param etag [::String]
1421
1451
  # If provided, this value must match the current value of the
1422
- # target RestorePlan's {::Google::Cloud::GkeBackup::V1::RestorePlan#etag etag} field or the request is
1423
- # rejected.
1452
+ # target RestorePlan's {::Google::Cloud::GkeBackup::V1::RestorePlan#etag etag}
1453
+ # field or the request is rejected.
1424
1454
  # @param force [::Boolean]
1425
1455
  # If set to true, any Restores below this RestorePlan will also be deleted.
1426
1456
  # Otherwise, the request will only succeed if the RestorePlan has no
@@ -1488,18 +1518,18 @@ module Google
1488
1518
  #
1489
1519
  # @param parent [::String]
1490
1520
  # Required. The RestorePlan within which to create the Restore.
1491
- # Format: projects/*/locations/*/restorePlans/*
1521
+ # Format: `projects/*/locations/*/restorePlans/*`
1492
1522
  # @param restore [::Google::Cloud::GkeBackup::V1::Restore, ::Hash]
1493
1523
  # Required. The restore resource to create.
1494
1524
  # @param restore_id [::String]
1495
1525
  # Required. The client-provided short name for the Restore resource.
1496
1526
  # This name must:
1497
1527
  #
1498
- # - be between 1 and 63 characters long (inclusive)
1499
- # - consist of only lower-case ASCII letters, numbers, and dashes
1500
- # - start with a lower-case letter
1501
- # - end with a lower-case letter or number
1502
- # - be unique within the set of Restores in this RestorePlan.
1528
+ # - be between 1 and 63 characters long (inclusive)
1529
+ # - consist of only lower-case ASCII letters, numbers, and dashes
1530
+ # - start with a lower-case letter
1531
+ # - end with a lower-case letter or number
1532
+ # - be unique within the set of Restores in this RestorePlan.
1503
1533
  # @yield [result, operation] Access the result along with the TransportOperation object
1504
1534
  # @yieldparam result [::Gapic::Operation]
1505
1535
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -1563,7 +1593,7 @@ module Google
1563
1593
  #
1564
1594
  # @param parent [::String]
1565
1595
  # Required. The RestorePlan that contains the Restores to list.
1566
- # Format: projects/*/locations/*/restorePlans/*
1596
+ # Format: `projects/*/locations/*/restorePlans/*`
1567
1597
  # @param page_size [::Integer]
1568
1598
  # The target number of results to return in a single response.
1569
1599
  # If not specified, a default value will be chosen by the service.
@@ -1644,7 +1674,7 @@ module Google
1644
1674
  #
1645
1675
  # @param name [::String]
1646
1676
  # Required. Name of the restore resource.
1647
- # Format: projects/*/locations/*/restorePlans/*/restores/*
1677
+ # Format: `projects/*/locations/*/restorePlans/*/restores/*`
1648
1678
  # @yield [result, operation] Access the result along with the TransportOperation object
1649
1679
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::Restore]
1650
1680
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -1706,8 +1736,8 @@ module Google
1706
1736
  # the default parameter values, pass an empty Hash as a request object (see above).
1707
1737
  #
1708
1738
  # @param restore [::Google::Cloud::GkeBackup::V1::Restore, ::Hash]
1709
- # Required. A new version of the Restore resource that contains updated fields.
1710
- # This may be sparsely populated if an `update_mask` is provided.
1739
+ # Required. A new version of the Restore resource that contains updated
1740
+ # fields. This may be sparsely populated if an `update_mask` is provided.
1711
1741
  # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1712
1742
  # This is used to specify the fields to be overwritten in the
1713
1743
  # Restore targeted for update. The values for each of these
@@ -1780,11 +1810,11 @@ module Google
1780
1810
  #
1781
1811
  # @param name [::String]
1782
1812
  # Required. Full name of the Restore
1783
- # Format: projects/*/locations/*/restorePlans/*/restores/*
1813
+ # Format: `projects/*/locations/*/restorePlans/*/restores/*`
1784
1814
  # @param etag [::String]
1785
1815
  # If provided, this value must match the current value of the
1786
- # target Restore's {::Google::Cloud::GkeBackup::V1::Restore#etag etag} field or the request is
1787
- # rejected.
1816
+ # target Restore's {::Google::Cloud::GkeBackup::V1::Restore#etag etag} field or
1817
+ # the request is rejected.
1788
1818
  # @param force [::Boolean]
1789
1819
  # If set to true, any VolumeRestores below this restore will also be deleted.
1790
1820
  # Otherwise, the request will only succeed if the restore has no
@@ -1852,7 +1882,7 @@ module Google
1852
1882
  #
1853
1883
  # @param parent [::String]
1854
1884
  # Required. The Restore that contains the VolumeRestores to list.
1855
- # Format: projects/*/locations/*/restorePlans/*/restores/*
1885
+ # Format: `projects/*/locations/*/restorePlans/*/restores/*`
1856
1886
  # @param page_size [::Integer]
1857
1887
  # The target number of results to return in a single response.
1858
1888
  # If not specified, a default value will be chosen by the service.
@@ -1934,7 +1964,7 @@ module Google
1934
1964
  #
1935
1965
  # @param name [::String]
1936
1966
  # Required. Full name of the VolumeRestore resource.
1937
- # Format: projects/*/locations/*/restorePlans/*/restores/*/volumeRestores/*
1967
+ # Format: `projects/*/locations/*/restorePlans/*/restores/*/volumeRestores/*`
1938
1968
  # @yield [result, operation] Access the result along with the TransportOperation object
1939
1969
  # @yieldparam result [::Google::Cloud::GkeBackup::V1::VolumeRestore]
1940
1970
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -2065,6 +2095,13 @@ module Google
2065
2095
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
2066
2096
  config_attr :quota_project, nil, ::String, nil
2067
2097
 
2098
+ # @private
2099
+ # Overrides for http bindings for the RPCs of this service
2100
+ # are only used when this service is used as mixin, and only
2101
+ # by the host service.
2102
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
2103
+ config_attr :bindings_override, {}, ::Hash, nil
2104
+
2068
2105
  # @private
2069
2106
  def initialize parent_config = nil
2070
2107
  @parent_config = parent_config unless parent_config.nil?
@@ -21,6 +21,7 @@ require "gapic/config"
21
21
  require "gapic/config/method"
22
22
 
23
23
  require "google/cloud/gke_backup/v1/version"
24
+ require "google/cloud/gke_backup/v1/bindings_override"
24
25
 
25
26
  require "google/cloud/gke_backup/v1/backup_for_gke/credentials"
26
27
  require "google/cloud/gke_backup/v1/backup_for_gke/paths"
@@ -0,0 +1,255 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2023 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "gapic/config"
20
+
21
+ module Google
22
+ module Cloud
23
+ module GkeBackup
24
+ ##
25
+ # @example Loading just the REST part of this package, including all its services, and instantiating a REST client
26
+ #
27
+ # require "google/cloud/gke_backup/v1/rest"
28
+ # client = ::Google::Cloud::GkeBackup::V1::BackupForGKE::Rest::Client.new
29
+ #
30
+ module V1
31
+ ##
32
+ # @private
33
+ # Initialize the mixin bindings configuration
34
+ #
35
+ def self.configure
36
+ @configure ||= begin
37
+ namespace = ["Google", "Cloud", "GkeBackup"]
38
+ parent_config = while namespace.any?
39
+ parent_name = namespace.join "::"
40
+ parent_const = const_get parent_name
41
+ break parent_const.configure if parent_const.respond_to? :configure
42
+ namespace.pop
43
+ end
44
+
45
+ default_config = Configuration.new parent_config
46
+ default_config.bindings_override["google.cloud.location.Locations.GetLocation"] = [
47
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
48
+ uri_method: :get,
49
+ uri_template: "/v1/{name}",
50
+ matches: [
51
+ ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
52
+ ],
53
+ body: nil
54
+ )
55
+ ]
56
+ default_config.bindings_override["google.cloud.location.Locations.ListLocations"] = [
57
+
58
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
59
+ uri_method: :get,
60
+ uri_template: "/v1/{name}/locations",
61
+ matches: [
62
+ ["name", %r{^projects/[^/]+/?$}, false]
63
+ ],
64
+ body: nil
65
+ )
66
+ ]
67
+ default_config.bindings_override["google.iam.v1.IAMPolicy.GetIamPolicy"] = [
68
+
69
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
70
+ uri_method: :get,
71
+ uri_template: "/v1/{resource}:getIamPolicy",
72
+ matches: [
73
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/?$}, false]
74
+ ],
75
+ body: nil
76
+ ),
77
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
78
+ uri_method: :get,
79
+ uri_template: "/v1/{resource}:getIamPolicy",
80
+ matches: [
81
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/?$}, false]
82
+ ],
83
+ body: nil
84
+ ),
85
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
86
+ uri_method: :get,
87
+ uri_template: "/v1/{resource}:getIamPolicy",
88
+ matches: [
89
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/volumeBackups/[^/]+/?$}, false]
90
+ ],
91
+ body: nil
92
+ ),
93
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
94
+ uri_method: :get,
95
+ uri_template: "/v1/{resource}:getIamPolicy",
96
+ matches: [
97
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/?$}, false]
98
+ ],
99
+ body: nil
100
+ ),
101
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
102
+ uri_method: :get,
103
+ uri_template: "/v1/{resource}:getIamPolicy",
104
+ matches: [
105
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/?$}, false]
106
+ ],
107
+ body: nil
108
+ ),
109
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
110
+ uri_method: :get,
111
+ uri_template: "/v1/{resource}:getIamPolicy",
112
+ matches: [
113
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/volumeRestores/[^/]+/?$}, false]
114
+ ],
115
+ body: nil
116
+ )
117
+ ]
118
+ default_config.bindings_override["google.iam.v1.IAMPolicy.SetIamPolicy"] = [
119
+
120
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
121
+ uri_method: :post,
122
+ uri_template: "/v1/{resource}:setIamPolicy",
123
+ matches: [
124
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/?$}, false]
125
+ ],
126
+ body: "*"
127
+ ),
128
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
129
+ uri_method: :post,
130
+ uri_template: "/v1/{resource}:setIamPolicy",
131
+ matches: [
132
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/?$}, false]
133
+ ],
134
+ body: "*"
135
+ ),
136
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
137
+ uri_method: :post,
138
+ uri_template: "/v1/{resource}:setIamPolicy",
139
+ matches: [
140
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/volumeBackups/[^/]+/?$}, false]
141
+ ],
142
+ body: "*"
143
+ ),
144
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
145
+ uri_method: :post,
146
+ uri_template: "/v1/{resource}:setIamPolicy",
147
+ matches: [
148
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/?$}, false]
149
+ ],
150
+ body: "*"
151
+ ),
152
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
153
+ uri_method: :post,
154
+ uri_template: "/v1/{resource}:setIamPolicy",
155
+ matches: [
156
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/?$}, false]
157
+ ],
158
+ body: "*"
159
+ ),
160
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
161
+ uri_method: :post,
162
+ uri_template: "/v1/{resource}:setIamPolicy",
163
+ matches: [
164
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/volumeRestores/[^/]+/?$}, false]
165
+ ],
166
+ body: "*"
167
+ )
168
+ ]
169
+ default_config.bindings_override["google.iam.v1.IAMPolicy.TestIamPermissions"] = [
170
+
171
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
172
+ uri_method: :post,
173
+ uri_template: "/v1/{resource}:testIamPermissions",
174
+ matches: [
175
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/?$}, false]
176
+ ],
177
+ body: "*"
178
+ ),
179
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
180
+ uri_method: :post,
181
+ uri_template: "/v1/{resource}:testIamPermissions",
182
+ matches: [
183
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/?$}, false]
184
+ ],
185
+ body: "*"
186
+ ),
187
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
188
+ uri_method: :post,
189
+ uri_template: "/v1/{resource}:testIamPermissions",
190
+ matches: [
191
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/backupPlans/[^/]+/backups/[^/]+/volumeBackups/[^/]+/?$}, false]
192
+ ],
193
+ body: "*"
194
+ ),
195
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
196
+ uri_method: :post,
197
+ uri_template: "/v1/{resource}:testIamPermissions",
198
+ matches: [
199
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/?$}, false]
200
+ ],
201
+ body: "*"
202
+ ),
203
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
204
+ uri_method: :post,
205
+ uri_template: "/v1/{resource}:testIamPermissions",
206
+ matches: [
207
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/?$}, false]
208
+ ],
209
+ body: "*"
210
+ ),
211
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
212
+ uri_method: :post,
213
+ uri_template: "/v1/{resource}:testIamPermissions",
214
+ matches: [
215
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/restorePlans/[^/]+/restores/[^/]+/volumeRestores/[^/]+/?$}, false]
216
+ ],
217
+ body: "*"
218
+ )
219
+ ]
220
+ default_config
221
+ end
222
+ yield @configure if block_given?
223
+ @configure
224
+ end
225
+
226
+ ##
227
+ # @private
228
+ # Configuration class for the google.cloud.gkebackup.v1 package.
229
+ #
230
+ # This class contains common configuration for all services
231
+ # of the google.cloud.gkebackup.v1 package.
232
+ #
233
+ # This configuration is for internal use of the client library classes,
234
+ # and it is not intended that the end-users will read or change it.
235
+ #
236
+ class Configuration
237
+ extend ::Gapic::Config
238
+
239
+ # @private
240
+ # Overrides for http bindings for the RPC of the mixins for this package.
241
+ # Services in this package should use these when creating clients for the mixin services.
242
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
243
+ config_attr :bindings_override, {}, ::Hash, nil
244
+
245
+ # @private
246
+ def initialize parent_config = nil
247
+ @parent_config = parent_config unless parent_config.nil?
248
+
249
+ yield self if block_given?
250
+ end
251
+ end
252
+ end
253
+ end
254
+ end
255
+ end
@@ -17,6 +17,7 @@
17
17
  # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
18
 
19
19
  require "google/cloud/gke_backup/v1/backup_for_gke/rest"
20
+ require "google/cloud/gke_backup/v1/bindings_override"
20
21
  require "google/cloud/gke_backup/v1/version"
21
22
 
22
23
  module Google
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module GkeBackup
23
23
  module V1
24
- VERSION = "0.4.0"
24
+ VERSION = "0.5.1"
25
25
  end
26
26
  end
27
27
  end