google-cloud-apigee_registry-v1 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7012cd6d477eea878a01cfd064edb058bc520988f79d9060625a41d75bfa816e
4
- data.tar.gz: 60a7d7093c4e2b88be3b67267b7fcd55abe56205a64745f15bd9689c91239d32
3
+ metadata.gz: 156728116ba847a4ad59a8c58ef162d81d6474a0a927fddec48673d5210bafe1
4
+ data.tar.gz: 0b87f057c3ab6ba497c105aefbf82b44a94ed010a1d1dec03c410a9339453fd4
5
5
  SHA512:
6
- metadata.gz: fcb419ddd225adb649da9890a0394a1ba2a85950f7c5597602d97e4c8e0ce856aba3c4d37172623aa1843d853eefa018ffa8658958fc3db2bcae1e9e0e1208ba
7
- data.tar.gz: 47a6b92fdae0513a0025f3bfd164b1dbf75642ccd8fdd7f6c1cbf250d8da7c577481a60e1d541451e274ce54702c071ba8521cebc214e20eb066b23fe4b2cbaa
6
+ metadata.gz: f71c2bef6e33976ebf985d781822c040f21a74d200ef0dafe8a2dc94f75204649cd433ddae2b561262636f960c7ba0fae1c77325cfb563c6cd91e4378edef6cc
7
+ data.tar.gz: 478054668a86dbae0a45452a565287a2b82c00ee9db2c68fa5fc56f13761fed911340032f2b6b5ccc874acf51e8ed8b5ca268b3a93bde9c6a9a3ed62f062343e
data/AUTHENTICATION.md CHANGED
@@ -112,7 +112,7 @@ credentials are discovered.
112
112
  To configure your system for this, simply:
113
113
 
114
114
  1. [Download and install the Cloud SDK](https://cloud.google.com/sdk)
115
- 2. Authenticate using OAuth 2.0 `$ gcloud auth login`
115
+ 2. Authenticate using OAuth 2.0 `$ gcloud auth application-default login`
116
116
  3. Write code as if already authenticated.
117
117
 
118
118
  **NOTE:** This is _not_ recommended for running in production. The Cloud SDK
data/README.md CHANGED
@@ -46,7 +46,7 @@ for general usage information.
46
46
  ## Enabling Logging
47
47
 
48
48
  To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
49
- The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib/libdoc/logger/rdoc/Logger.html) as shown below,
49
+ The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/current/stdlibs/logger/Logger.html) as shown below,
50
50
  or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
51
51
  that will write logs to [Cloud Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
52
52
  and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
@@ -0,0 +1,351 @@
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 ApigeeRegistry
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/apigee_registry/v1/rest"
28
+ # client = ::Google::Cloud::ApigeeRegistry::V1::Provisioning::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", "ApigeeRegistry"]
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/[^/]+/apis/[^/]+/?$}, 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/[^/]+/apis/[^/]+/deployments/[^/]+/?$}, 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/[^/]+/apis/[^/]+/versions/[^/]+/?$}, 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/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/?$}, 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/[^/]+/artifacts/[^/]+/?$}, 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/[^/]+/apis/[^/]+/artifacts/[^/]+/?$}, false]
114
+ ],
115
+ body: nil
116
+ ),
117
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
118
+ uri_method: :get,
119
+ uri_template: "/v1/{resource}:getIamPolicy",
120
+ matches: [
121
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/artifacts/[^/]+/?$}, false]
122
+ ],
123
+ body: nil
124
+ ),
125
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
126
+ uri_method: :get,
127
+ uri_template: "/v1/{resource}:getIamPolicy",
128
+ matches: [
129
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/artifacts/[^/]+/?$}, false]
130
+ ],
131
+ body: nil
132
+ ),
133
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
134
+ uri_method: :get,
135
+ uri_template: "/v1/{resource}:getIamPolicy",
136
+ matches: [
137
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
138
+ ],
139
+ body: nil
140
+ ),
141
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
142
+ uri_method: :get,
143
+ uri_template: "/v1/{resource}:getIamPolicy",
144
+ matches: [
145
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/runtime/?$}, false]
146
+ ],
147
+ body: nil
148
+ )
149
+ ]
150
+ default_config.bindings_override["google.iam.v1.IAMPolicy.SetIamPolicy"] = [
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/[^/]+/apis/[^/]+/?$}, 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/[^/]+/apis/[^/]+/deployments/[^/]+/?$}, false]
165
+ ],
166
+ body: "*"
167
+ ),
168
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
169
+ uri_method: :post,
170
+ uri_template: "/v1/{resource}:setIamPolicy",
171
+ matches: [
172
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/?$}, false]
173
+ ],
174
+ body: "*"
175
+ ),
176
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
177
+ uri_method: :post,
178
+ uri_template: "/v1/{resource}:setIamPolicy",
179
+ matches: [
180
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/?$}, false]
181
+ ],
182
+ body: "*"
183
+ ),
184
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
185
+ uri_method: :post,
186
+ uri_template: "/v1/{resource}:setIamPolicy",
187
+ matches: [
188
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/artifacts/[^/]+/?$}, false]
189
+ ],
190
+ body: "*"
191
+ ),
192
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
193
+ uri_method: :post,
194
+ uri_template: "/v1/{resource}:setIamPolicy",
195
+ matches: [
196
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/artifacts/[^/]+/?$}, false]
197
+ ],
198
+ body: "*"
199
+ ),
200
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
201
+ uri_method: :post,
202
+ uri_template: "/v1/{resource}:setIamPolicy",
203
+ matches: [
204
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/artifacts/[^/]+/?$}, false]
205
+ ],
206
+ body: "*"
207
+ ),
208
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
209
+ uri_method: :post,
210
+ uri_template: "/v1/{resource}:setIamPolicy",
211
+ matches: [
212
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/artifacts/[^/]+/?$}, false]
213
+ ],
214
+ body: "*"
215
+ ),
216
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
217
+ uri_method: :post,
218
+ uri_template: "/v1/{resource}:setIamPolicy",
219
+ matches: [
220
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
221
+ ],
222
+ body: "*"
223
+ ),
224
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
225
+ uri_method: :post,
226
+ uri_template: "/v1/{resource}:setIamPolicy",
227
+ matches: [
228
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/runtime/?$}, false]
229
+ ],
230
+ body: "*"
231
+ )
232
+ ]
233
+ default_config.bindings_override["google.iam.v1.IAMPolicy.TestIamPermissions"] = [
234
+
235
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
236
+ uri_method: :post,
237
+ uri_template: "/v1/{resource}:testIamPermissions",
238
+ matches: [
239
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/?$}, false]
240
+ ],
241
+ body: "*"
242
+ ),
243
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
244
+ uri_method: :post,
245
+ uri_template: "/v1/{resource}:testIamPermissions",
246
+ matches: [
247
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/deployments/[^/]+/?$}, false]
248
+ ],
249
+ body: "*"
250
+ ),
251
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
252
+ uri_method: :post,
253
+ uri_template: "/v1/{resource}:testIamPermissions",
254
+ matches: [
255
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/?$}, false]
256
+ ],
257
+ body: "*"
258
+ ),
259
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
260
+ uri_method: :post,
261
+ uri_template: "/v1/{resource}:testIamPermissions",
262
+ matches: [
263
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/?$}, false]
264
+ ],
265
+ body: "*"
266
+ ),
267
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
268
+ uri_method: :post,
269
+ uri_template: "/v1/{resource}:testIamPermissions",
270
+ matches: [
271
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/artifacts/[^/]+/?$}, false]
272
+ ],
273
+ body: "*"
274
+ ),
275
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
276
+ uri_method: :post,
277
+ uri_template: "/v1/{resource}:testIamPermissions",
278
+ matches: [
279
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/artifacts/[^/]+/?$}, false]
280
+ ],
281
+ body: "*"
282
+ ),
283
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
284
+ uri_method: :post,
285
+ uri_template: "/v1/{resource}:testIamPermissions",
286
+ matches: [
287
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/artifacts/[^/]+/?$}, false]
288
+ ],
289
+ body: "*"
290
+ ),
291
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
292
+ uri_method: :post,
293
+ uri_template: "/v1/{resource}:testIamPermissions",
294
+ matches: [
295
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/apis/[^/]+/versions/[^/]+/specs/[^/]+/artifacts/[^/]+/?$}, false]
296
+ ],
297
+ body: "*"
298
+ ),
299
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
300
+ uri_method: :post,
301
+ uri_template: "/v1/{resource}:testIamPermissions",
302
+ matches: [
303
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/instances/[^/]+/?$}, false]
304
+ ],
305
+ body: "*"
306
+ ),
307
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
308
+ uri_method: :post,
309
+ uri_template: "/v1/{resource}:testIamPermissions",
310
+ matches: [
311
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/runtime/?$}, false]
312
+ ],
313
+ body: "*"
314
+ )
315
+ ]
316
+ default_config
317
+ end
318
+ yield @configure if block_given?
319
+ @configure
320
+ end
321
+
322
+ ##
323
+ # @private
324
+ # Configuration class for the google.cloud.apigeeregistry.v1 package.
325
+ #
326
+ # This class contains common configuration for all services
327
+ # of the google.cloud.apigeeregistry.v1 package.
328
+ #
329
+ # This configuration is for internal use of the client library classes,
330
+ # and it is not intended that the end-users will read or change it.
331
+ #
332
+ class Configuration
333
+ extend ::Gapic::Config
334
+
335
+ # @private
336
+ # Overrides for http bindings for the RPC of the mixins for this package.
337
+ # Services in this package should use these when creating clients for the mixin services.
338
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
339
+ config_attr :bindings_override, {}, ::Hash, nil
340
+
341
+ # @private
342
+ def initialize parent_config = nil
343
+ @parent_config = parent_config unless parent_config.nil?
344
+
345
+ yield self if block_given?
346
+ end
347
+ end
348
+ end
349
+ end
350
+ end
351
+ end
@@ -232,14 +232,14 @@ module Google
232
232
  # # Call the create_instance method.
233
233
  # result = client.create_instance request
234
234
  #
235
- # # The returned object is of type Gapic::Operation. You can use this
236
- # # object to check the status of an operation, cancel it, or wait
237
- # # for results. Here is how to block until completion:
235
+ # # The returned object is of type Gapic::Operation. You can use it to
236
+ # # check the status of an operation, cancel it, or wait for results.
237
+ # # Here is how to wait for a response.
238
238
  # result.wait_until_done! timeout: 60
239
239
  # if result.response?
240
240
  # p result.response
241
241
  # else
242
- # puts "Error!"
242
+ # puts "No response received."
243
243
  # end
244
244
  #
245
245
  def create_instance request, options = nil
@@ -326,14 +326,14 @@ module Google
326
326
  # # Call the delete_instance method.
327
327
  # result = client.delete_instance request
328
328
  #
329
- # # The returned object is of type Gapic::Operation. You can use this
330
- # # object to check the status of an operation, cancel it, or wait
331
- # # for results. Here is how to block until completion:
329
+ # # The returned object is of type Gapic::Operation. You can use it to
330
+ # # check the status of an operation, cancel it, or wait for results.
331
+ # # Here is how to wait for a response.
332
332
  # result.wait_until_done! timeout: 60
333
333
  # if result.response?
334
334
  # p result.response
335
335
  # else
336
- # puts "Error!"
336
+ # puts "No response received."
337
337
  # end
338
338
  #
339
339
  def delete_instance request, options = nil
@@ -158,13 +158,11 @@ module Google
158
158
  # # Call the list_operations method.
159
159
  # result = client.list_operations request
160
160
  #
161
- # # The returned object is of type Gapic::PagedEnumerable. You can
162
- # # iterate over all elements by calling #each, and the enumerable
163
- # # will lazily make API calls to fetch subsequent pages. Other
164
- # # methods are also available for managing paging directly.
165
- # result.each do |response|
161
+ # # The returned object is of type Gapic::PagedEnumerable. You can iterate
162
+ # # over elements, and API calls will be issued to fetch pages as needed.
163
+ # result.each do |item|
166
164
  # # Each element is of type ::Google::Longrunning::Operation.
167
- # p response
165
+ # p item
168
166
  # end
169
167
  #
170
168
  def list_operations request, options = nil
@@ -253,14 +251,14 @@ module Google
253
251
  # # Call the get_operation method.
254
252
  # result = client.get_operation request
255
253
  #
256
- # # The returned object is of type Gapic::Operation. You can use this
257
- # # object to check the status of an operation, cancel it, or wait
258
- # # for results. Here is how to block until completion:
254
+ # # The returned object is of type Gapic::Operation. You can use it to
255
+ # # check the status of an operation, cancel it, or wait for results.
256
+ # # Here is how to wait for a response.
259
257
  # result.wait_until_done! timeout: 60
260
258
  # if result.response?
261
259
  # p result.response
262
260
  # else
263
- # puts "Error!"
261
+ # puts "No response received."
264
262
  # end
265
263
  #
266
264
  def get_operation request, options = nil
@@ -540,14 +538,14 @@ module Google
540
538
  # # Call the wait_operation method.
541
539
  # result = client.wait_operation request
542
540
  #
543
- # # The returned object is of type Gapic::Operation. You can use this
544
- # # object to check the status of an operation, cancel it, or wait
545
- # # for results. Here is how to block until completion:
541
+ # # The returned object is of type Gapic::Operation. You can use it to
542
+ # # check the status of an operation, cancel it, or wait for results.
543
+ # # Here is how to wait for a response.
546
544
  # result.wait_until_done! timeout: 60
547
545
  # if result.response?
548
546
  # p result.response
549
547
  # else
550
- # puts "Error!"
548
+ # puts "No response received."
551
549
  # end
552
550
  #
553
551
  def wait_operation request, options = nil