google-iam-v1 1.1.0 → 1.2.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 59f20a075f2106b81075d3074ba2f5547621c5f6c5af6018a0719b7c9f89b05a
|
4
|
+
data.tar.gz: 2bc0c0042a325abf8d47bc0d4fadae5ab1fbb881404ded6f2bf4626da8bc394d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2b359ba5e21f4ee48b1d3267cda5f3938875f0ca5d6d8d8d62ff19df5172a1eecc49cbba1781d86afbaa3e5cb7ba25926e745cb2501e11fdac20b7cdcc2326ac
|
7
|
+
data.tar.gz: 6db0e013f678e6696bac7871748a6965f99c3ac80a6c5a3c3711e55979c0fbe773ba322491c6c9e14b9e23c7eea8cb6700ca0ae9df09fe85af133a9f714488e9
|
@@ -178,8 +178,28 @@ module Google
|
|
178
178
|
universe_domain: @config.universe_domain,
|
179
179
|
channel_args: @config.channel_args,
|
180
180
|
interceptors: @config.interceptors,
|
181
|
-
channel_pool_config: @config.channel_pool
|
181
|
+
channel_pool_config: @config.channel_pool,
|
182
|
+
logger: @config.logger
|
182
183
|
)
|
184
|
+
|
185
|
+
@iam_policy_stub.stub_logger&.info do |entry|
|
186
|
+
entry.set_system_name
|
187
|
+
entry.set_service
|
188
|
+
entry.message = "Created client for #{entry.service}"
|
189
|
+
entry.set_credentials_fields credentials
|
190
|
+
entry.set "customEndpoint", @config.endpoint if @config.endpoint
|
191
|
+
entry.set "defaultTimeout", @config.timeout if @config.timeout
|
192
|
+
entry.set "quotaProject", @quota_project_id if @quota_project_id
|
193
|
+
end
|
194
|
+
end
|
195
|
+
|
196
|
+
##
|
197
|
+
# The logger used for request/response debug logging.
|
198
|
+
#
|
199
|
+
# @return [Logger]
|
200
|
+
#
|
201
|
+
def logger
|
202
|
+
@iam_policy_stub.logger
|
183
203
|
end
|
184
204
|
|
185
205
|
# Service calls
|
@@ -279,7 +299,6 @@ module Google
|
|
279
299
|
|
280
300
|
@iam_policy_stub.call_rpc :set_iam_policy, request, options: options do |response, operation|
|
281
301
|
yield response, operation if block_given?
|
282
|
-
return response
|
283
302
|
end
|
284
303
|
rescue ::GRPC::BadStatus => e
|
285
304
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -371,7 +390,6 @@ module Google
|
|
371
390
|
|
372
391
|
@iam_policy_stub.call_rpc :get_iam_policy, request, options: options do |response, operation|
|
373
392
|
yield response, operation if block_given?
|
374
|
-
return response
|
375
393
|
end
|
376
394
|
rescue ::GRPC::BadStatus => e
|
377
395
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -469,7 +487,6 @@ module Google
|
|
469
487
|
|
470
488
|
@iam_policy_stub.call_rpc :test_iam_permissions, request, options: options do |response, operation|
|
471
489
|
yield response, operation if block_given?
|
472
|
-
return response
|
473
490
|
end
|
474
491
|
rescue ::GRPC::BadStatus => e
|
475
492
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -558,6 +575,11 @@ module Google
|
|
558
575
|
# default endpoint URL. The default value of nil uses the environment
|
559
576
|
# universe (usually the default "googleapis.com" universe).
|
560
577
|
# @return [::String,nil]
|
578
|
+
# @!attribute [rw] logger
|
579
|
+
# A custom logger to use for request/response debug logging, or the value
|
580
|
+
# `:default` (the default) to construct a default logger, or `nil` to
|
581
|
+
# explicitly disable logging.
|
582
|
+
# @return [::Logger,:default,nil]
|
561
583
|
#
|
562
584
|
class Configuration
|
563
585
|
extend ::Gapic::Config
|
@@ -582,6 +604,7 @@ module Google
|
|
582
604
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
583
605
|
config_attr :quota_project, nil, ::String, nil
|
584
606
|
config_attr :universe_domain, nil, ::String, nil
|
607
|
+
config_attr :logger, :default, ::Logger, nil, :default
|
585
608
|
|
586
609
|
# @private
|
587
610
|
def initialize parent_config = nil
|
@@ -171,8 +171,28 @@ module Google
|
|
171
171
|
endpoint: @config.endpoint,
|
172
172
|
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
173
173
|
universe_domain: @config.universe_domain,
|
174
|
-
credentials: credentials
|
174
|
+
credentials: credentials,
|
175
|
+
logger: @config.logger
|
175
176
|
)
|
177
|
+
|
178
|
+
@iam_policy_stub.logger(stub: true)&.info do |entry|
|
179
|
+
entry.set_system_name
|
180
|
+
entry.set_service
|
181
|
+
entry.message = "Created client for #{entry.service}"
|
182
|
+
entry.set_credentials_fields credentials
|
183
|
+
entry.set "customEndpoint", @config.endpoint if @config.endpoint
|
184
|
+
entry.set "defaultTimeout", @config.timeout if @config.timeout
|
185
|
+
entry.set "quotaProject", @quota_project_id if @quota_project_id
|
186
|
+
end
|
187
|
+
end
|
188
|
+
|
189
|
+
##
|
190
|
+
# The logger used for request/response debug logging.
|
191
|
+
#
|
192
|
+
# @return [Logger]
|
193
|
+
#
|
194
|
+
def logger
|
195
|
+
@iam_policy_stub.logger
|
176
196
|
end
|
177
197
|
|
178
198
|
# Service calls
|
@@ -267,7 +287,6 @@ module Google
|
|
267
287
|
|
268
288
|
@iam_policy_stub.set_iam_policy request, options, bindings_override: bindings_override do |result, operation|
|
269
289
|
yield result, operation if block_given?
|
270
|
-
return result
|
271
290
|
end
|
272
291
|
rescue ::Gapic::Rest::Error => e
|
273
292
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -354,7 +373,6 @@ module Google
|
|
354
373
|
|
355
374
|
@iam_policy_stub.get_iam_policy request, options, bindings_override: bindings_override do |result, operation|
|
356
375
|
yield result, operation if block_given?
|
357
|
-
return result
|
358
376
|
end
|
359
377
|
rescue ::Gapic::Rest::Error => e
|
360
378
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -447,7 +465,6 @@ module Google
|
|
447
465
|
|
448
466
|
@iam_policy_stub.test_iam_permissions request, options, bindings_override: bindings_override do |result, operation|
|
449
467
|
yield result, operation if block_given?
|
450
|
-
return result
|
451
468
|
end
|
452
469
|
rescue ::Gapic::Rest::Error => e
|
453
470
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -527,6 +544,11 @@ module Google
|
|
527
544
|
# default endpoint URL. The default value of nil uses the environment
|
528
545
|
# universe (usually the default "googleapis.com" universe).
|
529
546
|
# @return [::String,nil]
|
547
|
+
# @!attribute [rw] logger
|
548
|
+
# A custom logger to use for request/response debug logging, or the value
|
549
|
+
# `:default` (the default) to construct a default logger, or `nil` to
|
550
|
+
# explicitly disable logging.
|
551
|
+
# @return [::Logger,:default,nil]
|
530
552
|
#
|
531
553
|
class Configuration
|
532
554
|
extend ::Gapic::Config
|
@@ -555,6 +577,7 @@ module Google
|
|
555
577
|
# by the host service.
|
556
578
|
# @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
|
557
579
|
config_attr :bindings_override, {}, ::Hash, nil
|
580
|
+
config_attr :logger, :default, ::Logger, nil, :default
|
558
581
|
|
559
582
|
# @private
|
560
583
|
def initialize parent_config = nil
|
@@ -29,7 +29,8 @@ module Google
|
|
29
29
|
# including transcoding, making the REST call, and deserialing the response.
|
30
30
|
#
|
31
31
|
class ServiceStub
|
32
|
-
|
32
|
+
# @private
|
33
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger:
|
33
34
|
# These require statements are intentionally placed here to initialize
|
34
35
|
# the REST modules only when it's required.
|
35
36
|
require "gapic/rest"
|
@@ -39,7 +40,9 @@ module Google
|
|
39
40
|
universe_domain: universe_domain,
|
40
41
|
credentials: credentials,
|
41
42
|
numeric_enums: false,
|
42
|
-
|
43
|
+
service_name: self.class,
|
44
|
+
raise_faraday_errors: false,
|
45
|
+
logger: logger
|
43
46
|
end
|
44
47
|
|
45
48
|
##
|
@@ -60,6 +63,15 @@ module Google
|
|
60
63
|
@client_stub.endpoint
|
61
64
|
end
|
62
65
|
|
66
|
+
##
|
67
|
+
# The logger used for request/response debug logging.
|
68
|
+
#
|
69
|
+
# @return [Logger]
|
70
|
+
#
|
71
|
+
def logger stub: false
|
72
|
+
stub ? @client_stub.stub_logger : @client_stub.logger
|
73
|
+
end
|
74
|
+
|
63
75
|
##
|
64
76
|
# Baseline implementation for the set_iam_policy REST call
|
65
77
|
#
|
@@ -88,16 +100,18 @@ module Google
|
|
88
100
|
|
89
101
|
response = @client_stub.make_http_request(
|
90
102
|
verb,
|
91
|
-
uri:
|
92
|
-
body:
|
93
|
-
params:
|
103
|
+
uri: uri,
|
104
|
+
body: body || "",
|
105
|
+
params: query_string_params,
|
106
|
+
method_name: "set_iam_policy",
|
94
107
|
options: options
|
95
108
|
)
|
96
109
|
operation = ::Gapic::Rest::TransportOperation.new response
|
97
110
|
result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
98
|
-
|
99
|
-
|
100
|
-
|
111
|
+
catch :response do
|
112
|
+
yield result, operation if block_given?
|
113
|
+
result
|
114
|
+
end
|
101
115
|
end
|
102
116
|
|
103
117
|
##
|
@@ -128,16 +142,18 @@ module Google
|
|
128
142
|
|
129
143
|
response = @client_stub.make_http_request(
|
130
144
|
verb,
|
131
|
-
uri:
|
132
|
-
body:
|
133
|
-
params:
|
145
|
+
uri: uri,
|
146
|
+
body: body || "",
|
147
|
+
params: query_string_params,
|
148
|
+
method_name: "get_iam_policy",
|
134
149
|
options: options
|
135
150
|
)
|
136
151
|
operation = ::Gapic::Rest::TransportOperation.new response
|
137
152
|
result = ::Google::Iam::V1::Policy.decode_json response.body, ignore_unknown_fields: true
|
138
|
-
|
139
|
-
|
140
|
-
|
153
|
+
catch :response do
|
154
|
+
yield result, operation if block_given?
|
155
|
+
result
|
156
|
+
end
|
141
157
|
end
|
142
158
|
|
143
159
|
##
|
@@ -168,16 +184,18 @@ module Google
|
|
168
184
|
|
169
185
|
response = @client_stub.make_http_request(
|
170
186
|
verb,
|
171
|
-
uri:
|
172
|
-
body:
|
173
|
-
params:
|
187
|
+
uri: uri,
|
188
|
+
body: body || "",
|
189
|
+
params: query_string_params,
|
190
|
+
method_name: "test_iam_permissions",
|
174
191
|
options: options
|
175
192
|
)
|
176
193
|
operation = ::Gapic::Rest::TransportOperation.new response
|
177
194
|
result = ::Google::Iam::V1::TestIamPermissionsResponse.decode_json response.body, ignore_unknown_fields: true
|
178
|
-
|
179
|
-
|
180
|
-
|
195
|
+
catch :response do
|
196
|
+
yield result, operation if block_given?
|
197
|
+
result
|
198
|
+
end
|
181
199
|
end
|
182
200
|
|
183
201
|
##
|
@@ -306,9 +306,28 @@ module Google
|
|
306
306
|
# @!attribute [rw] common
|
307
307
|
# @return [::Google::Api::CommonLanguageSettings]
|
308
308
|
# Some settings.
|
309
|
+
# @!attribute [rw] renamed_services
|
310
|
+
# @return [::Google::Protobuf::Map{::String => ::String}]
|
311
|
+
# Map of service names to renamed services. Keys are the package relative
|
312
|
+
# service names and values are the name to be used for the service client
|
313
|
+
# and call options.
|
314
|
+
#
|
315
|
+
# publishing:
|
316
|
+
# go_settings:
|
317
|
+
# renamed_services:
|
318
|
+
# Publisher: TopicAdmin
|
309
319
|
class GoSettings
|
310
320
|
include ::Google::Protobuf::MessageExts
|
311
321
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
322
|
+
|
323
|
+
# @!attribute [rw] key
|
324
|
+
# @return [::String]
|
325
|
+
# @!attribute [rw] value
|
326
|
+
# @return [::String]
|
327
|
+
class RenamedServicesEntry
|
328
|
+
include ::Google::Protobuf::MessageExts
|
329
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
330
|
+
end
|
312
331
|
end
|
313
332
|
|
314
333
|
# Describes the generator configuration for a method.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-iam-v1
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-12-
|
11
|
+
date: 2024-12-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gapic-common
|
@@ -16,7 +16,7 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.24.0
|
20
20
|
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
22
|
version: 2.a
|
@@ -26,7 +26,7 @@ dependencies:
|
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 0.
|
29
|
+
version: 0.24.0
|
30
30
|
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
32
|
version: 2.a
|
@@ -117,7 +117,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
117
117
|
- !ruby/object:Gem::Version
|
118
118
|
version: '0'
|
119
119
|
requirements: []
|
120
|
-
rubygems_version: 3.5.
|
120
|
+
rubygems_version: 3.5.23
|
121
121
|
signing_key:
|
122
122
|
specification_version: 4
|
123
123
|
summary: Manages access control for Google Cloud Platform resources.
|