google-cloud-bigtable 0.4.1 → 0.4.2

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: a605ac8a0dfac5a1e8862e5c3eb192fc51e335ea158910d913463bd3b229739f
4
- data.tar.gz: 806129138a670c1843f9c2e34de29bb8a6b0317952823c089e57fcf28db13b48
3
+ metadata.gz: 7f160f91302ae07b76627873f6235f8d94f951c5cbdbd4eb33831eb973e95ad4
4
+ data.tar.gz: 2fb74343e563b79b47d1eb3c4a219e8c0351dfdda4f6c6da258b9aa6a0c014e8
5
5
  SHA512:
6
- metadata.gz: 05da3c7c80c0e5aaae3702e631c41f99fd67d8604265aca4df78f1ace09193a27a30071ad6def98c522d08117508107b4440b054a7e551d0a982fed49cb8f528
7
- data.tar.gz: 52f89f7a81f550e56e46e184cd5ff7633a4955386c1316d6596157645a15a57a6667576e995fb2e6482e0429fa9a32ae9fe3e3914cdfb06582bb1f54d0597470
6
+ metadata.gz: 7ff2cb72abf932398f1c521552be53afeaaa31834cab32e3f622b76fef6830d60cca65f502aded25437000d2181a9a97d1c75866bfed91be79170c664bd505cc
7
+ data.tar.gz: 6f470f2cb38bcb1a93bf7a1e0302eec31a75344ae02fa22bdfd2fad7b8db3e99d488370d67763b7a66eaf0463af2566e3d5b4bb380d206540eef121218803e52
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Release History
2
2
 
3
+ ### 0.4.2 / 2019-07-09
4
+
5
+ * Add IAM GetPolicyOptions in the lower-level interface.
6
+ * Custom metadata headers are honored by long running operations calls.
7
+ * Support overriding service host and port in the lower-level interface.
8
+
3
9
  ### 0.4.1 / 2019-06-11
4
10
 
5
11
  * Enable grpc.service_config_disable_resolution
@@ -114,6 +114,10 @@ module Google
114
114
  # The default timeout, in seconds, for calls made through this client.
115
115
  # @param metadata [Hash]
116
116
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
117
+ # @param service_address [String]
118
+ # Override for the service hostname, or `nil` to leave as the default.
119
+ # @param service_port [Integer]
120
+ # Override for the service port, or `nil` to leave as the default.
117
121
  # @param exception_transformer [Proc]
118
122
  # An optional proc that intercepts any exceptions raised during an API call to inject
119
123
  # custom error handling.
@@ -123,6 +127,8 @@ module Google
123
127
  client_config: nil,
124
128
  timeout: nil,
125
129
  metadata: nil,
130
+ service_address: nil,
131
+ service_port: nil,
126
132
  exception_transformer: nil,
127
133
  lib_name: nil,
128
134
  lib_version: nil
@@ -134,6 +140,8 @@ module Google
134
140
  metadata: metadata,
135
141
  exception_transformer: exception_transformer,
136
142
  lib_name: lib_name,
143
+ service_address: service_address,
144
+ service_port: service_port,
137
145
  lib_version: lib_version
138
146
  }.select { |_, v| v != nil }
139
147
  Google::Cloud::Bigtable::Admin::V2::BigtableInstanceAdminClient.new(**kwargs)
@@ -174,6 +182,10 @@ module Google
174
182
  # The default timeout, in seconds, for calls made through this client.
175
183
  # @param metadata [Hash]
176
184
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
185
+ # @param service_address [String]
186
+ # Override for the service hostname, or `nil` to leave as the default.
187
+ # @param service_port [Integer]
188
+ # Override for the service port, or `nil` to leave as the default.
177
189
  # @param exception_transformer [Proc]
178
190
  # An optional proc that intercepts any exceptions raised during an API call to inject
179
191
  # custom error handling.
@@ -183,6 +195,8 @@ module Google
183
195
  client_config: nil,
184
196
  timeout: nil,
185
197
  metadata: nil,
198
+ service_address: nil,
199
+ service_port: nil,
186
200
  exception_transformer: nil,
187
201
  lib_name: nil,
188
202
  lib_version: nil
@@ -194,6 +208,8 @@ module Google
194
208
  metadata: metadata,
195
209
  exception_transformer: exception_transformer,
196
210
  lib_name: lib_name,
211
+ service_address: service_address,
212
+ service_port: service_port,
197
213
  lib_version: lib_version
198
214
  }.select { |_, v| v != nil }
199
215
  Google::Cloud::Bigtable::Admin::V2::BigtableTableAdminClient.new(**kwargs)
@@ -199,6 +199,10 @@ module Google
199
199
  # The default timeout, in seconds, for calls made through this client.
200
200
  # @param metadata [Hash]
201
201
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
202
+ # @param service_address [String]
203
+ # Override for the service hostname, or `nil` to leave as the default.
204
+ # @param service_port [Integer]
205
+ # Override for the service port, or `nil` to leave as the default.
202
206
  # @param exception_transformer [Proc]
203
207
  # An optional proc that intercepts any exceptions raised during an API call to inject
204
208
  # custom error handling.
@@ -208,6 +212,8 @@ module Google
208
212
  client_config: {},
209
213
  timeout: DEFAULT_TIMEOUT,
210
214
  metadata: nil,
215
+ service_address: nil,
216
+ service_port: nil,
211
217
  exception_transformer: nil,
212
218
  lib_name: nil,
213
219
  lib_version: ""
@@ -225,7 +231,10 @@ module Google
225
231
  client_config: client_config,
226
232
  timeout: timeout,
227
233
  lib_name: lib_name,
234
+ service_address: service_address,
235
+ service_port: service_port,
228
236
  lib_version: lib_version,
237
+ metadata: metadata,
229
238
  )
230
239
 
231
240
  if credentials.is_a?(String) || credentials.is_a?(Hash)
@@ -271,8 +280,8 @@ module Google
271
280
  end
272
281
 
273
282
  # Allow overriding the service path/port in subclasses.
274
- service_path = self.class::SERVICE_ADDRESS
275
- port = self.class::DEFAULT_SERVICE_PORT
283
+ service_path = service_address || self.class::SERVICE_ADDRESS
284
+ port = service_port || self.class::DEFAULT_SERVICE_PORT
276
285
  interceptors = self.class::GRPC_INTERCEPTORS
277
286
  @bigtable_instance_admin_stub = Google::Gax::Grpc.create_stub(
278
287
  service_path,
@@ -1307,6 +1316,11 @@ module Google
1307
1316
  # @param resource [String]
1308
1317
  # REQUIRED: The resource for which the policy is being requested.
1309
1318
  # See the operation documentation for the appropriate value for this field.
1319
+ # @param options_ [Google::Iam::V1::GetPolicyOptions | Hash]
1320
+ # OPTIONAL: A `GetPolicyOptions` object for specifying options to
1321
+ # `GetIamPolicy`. This field is only used by Cloud IAM.
1322
+ # A hash of the same form as `Google::Iam::V1::GetPolicyOptions`
1323
+ # can also be provided.
1310
1324
  # @param options [Google::Gax::CallOptions]
1311
1325
  # Overrides the default settings for this call, e.g, timeout,
1312
1326
  # retries, etc.
@@ -1324,10 +1338,12 @@ module Google
1324
1338
 
1325
1339
  def get_iam_policy \
1326
1340
  resource,
1341
+ options_: nil,
1327
1342
  options: nil,
1328
1343
  &block
1329
1344
  req = {
1330
- resource: resource
1345
+ resource: resource,
1346
+ options: options_
1331
1347
  }.delete_if { |_, v| v.nil? }
1332
1348
  req = Google::Gax::to_proto(req, Google::Iam::V1::GetIamPolicyRequest)
1333
1349
  @get_iam_policy.call(req, options, &block)
@@ -194,6 +194,10 @@ module Google
194
194
  # The default timeout, in seconds, for calls made through this client.
195
195
  # @param metadata [Hash]
196
196
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
197
+ # @param service_address [String]
198
+ # Override for the service hostname, or `nil` to leave as the default.
199
+ # @param service_port [Integer]
200
+ # Override for the service port, or `nil` to leave as the default.
197
201
  # @param exception_transformer [Proc]
198
202
  # An optional proc that intercepts any exceptions raised during an API call to inject
199
203
  # custom error handling.
@@ -203,6 +207,8 @@ module Google
203
207
  client_config: {},
204
208
  timeout: DEFAULT_TIMEOUT,
205
209
  metadata: nil,
210
+ service_address: nil,
211
+ service_port: nil,
206
212
  exception_transformer: nil,
207
213
  lib_name: nil,
208
214
  lib_version: ""
@@ -220,7 +226,10 @@ module Google
220
226
  client_config: client_config,
221
227
  timeout: timeout,
222
228
  lib_name: lib_name,
229
+ service_address: service_address,
230
+ service_port: service_port,
223
231
  lib_version: lib_version,
232
+ metadata: metadata,
224
233
  )
225
234
 
226
235
  if credentials.is_a?(String) || credentials.is_a?(Hash)
@@ -266,8 +275,8 @@ module Google
266
275
  end
267
276
 
268
277
  # Allow overriding the service path/port in subclasses.
269
- service_path = self.class::SERVICE_ADDRESS
270
- port = self.class::DEFAULT_SERVICE_PORT
278
+ service_path = service_address || self.class::SERVICE_ADDRESS
279
+ port = service_port || self.class::DEFAULT_SERVICE_PORT
271
280
  interceptors = self.class::GRPC_INTERCEPTORS
272
281
  @bigtable_table_admin_stub = Google::Gax::Grpc.create_stub(
273
282
  service_path,
@@ -34,6 +34,10 @@ module Google
34
34
  # @return [String]
35
35
  # REQUIRED: The resource for which the policy is being requested.
36
36
  # See the operation documentation for the appropriate value for this field.
37
+ # @!attribute [rw] options
38
+ # @return [Google::Iam::V1::GetPolicyOptions]
39
+ # OPTIONAL: A `GetPolicyOptions` object for specifying options to
40
+ # `GetIamPolicy`. This field is only used by Cloud IAM.
37
41
  class GetIamPolicyRequest; end
38
42
 
39
43
  # Request message for `TestIamPermissions` method.
@@ -0,0 +1,29 @@
1
+ # Copyright 2019 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # https://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+
16
+ module Google
17
+ module Iam
18
+ module V1
19
+ # Encapsulates settings provided to GetIamPolicy.
20
+ # @!attribute [rw] requested_policy_version
21
+ # @return [Integer]
22
+ # Optional. The policy format version to be returned.
23
+ # Acceptable values are 0 and 1.
24
+ # If the value is 0, or the field is omitted, policy format version 1 will be
25
+ # returned.
26
+ class GetPolicyOptions; end
27
+ end
28
+ end
29
+ end
@@ -145,7 +145,7 @@ module Google
145
145
  # # filter = Google::Cloud::Bigtable::RowFilter.key("user-*")
146
146
  #
147
147
  # table.read_rows(filter: filter, limit: 10).each do |row|
148
- # puts rowow
148
+ # puts row
149
149
  # end
150
150
  #
151
151
  def read_rows \
@@ -108,6 +108,10 @@ module Google
108
108
  # The default timeout, in seconds, for calls made through this client.
109
109
  # @param metadata [Hash]
110
110
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
111
+ # @param service_address [String]
112
+ # Override for the service hostname, or `nil` to leave as the default.
113
+ # @param service_port [Integer]
114
+ # Override for the service port, or `nil` to leave as the default.
111
115
  # @param exception_transformer [Proc]
112
116
  # An optional proc that intercepts any exceptions raised during an API call to inject
113
117
  # custom error handling.
@@ -117,6 +121,8 @@ module Google
117
121
  client_config: nil,
118
122
  timeout: nil,
119
123
  metadata: nil,
124
+ service_address: nil,
125
+ service_port: nil,
120
126
  exception_transformer: nil,
121
127
  lib_name: nil,
122
128
  lib_version: nil
@@ -128,6 +134,8 @@ module Google
128
134
  metadata: metadata,
129
135
  exception_transformer: exception_transformer,
130
136
  lib_name: lib_name,
137
+ service_address: service_address,
138
+ service_port: service_port,
131
139
  lib_version: lib_version
132
140
  }.select { |_, v| v != nil }
133
141
  Google::Cloud::Bigtable::V2::BigtableClient.new(**kwargs)
@@ -109,6 +109,10 @@ module Google
109
109
  # The default timeout, in seconds, for calls made through this client.
110
110
  # @param metadata [Hash]
111
111
  # Default metadata to be sent with each request. This can be overridden on a per call basis.
112
+ # @param service_address [String]
113
+ # Override for the service hostname, or `nil` to leave as the default.
114
+ # @param service_port [Integer]
115
+ # Override for the service port, or `nil` to leave as the default.
112
116
  # @param exception_transformer [Proc]
113
117
  # An optional proc that intercepts any exceptions raised during an API call to inject
114
118
  # custom error handling.
@@ -118,6 +122,8 @@ module Google
118
122
  client_config: {},
119
123
  timeout: DEFAULT_TIMEOUT,
120
124
  metadata: nil,
125
+ service_address: nil,
126
+ service_port: nil,
121
127
  exception_transformer: nil,
122
128
  lib_name: nil,
123
129
  lib_version: ""
@@ -171,8 +177,8 @@ module Google
171
177
  end
172
178
 
173
179
  # Allow overriding the service path/port in subclasses.
174
- service_path = self.class::SERVICE_ADDRESS
175
- port = self.class::DEFAULT_SERVICE_PORT
180
+ service_path = service_address || self.class::SERVICE_ADDRESS
181
+ port = service_port || self.class::DEFAULT_SERVICE_PORT
176
182
  interceptors = self.class::GRPC_INTERCEPTORS
177
183
  @bigtable_stub = Google::Gax::Grpc.create_stub(
178
184
  service_path,
@@ -16,7 +16,7 @@
16
16
  module Google
17
17
  module Cloud
18
18
  module Bigtable
19
- VERSION = "0.4.1".freeze
19
+ VERSION = "0.4.2".freeze
20
20
  end
21
21
  end
22
22
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-bigtable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-06-14 00:00:00.000000000 Z
11
+ date: 2019-07-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-gax
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.0'
19
+ version: '1.7'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.0'
26
+ version: '1.7'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: grpc-google-iam-v1
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -205,6 +205,7 @@ files:
205
205
  - lib/google/cloud/bigtable/admin/v2/doc/google/bigtable/admin/v2/instance.rb
206
206
  - lib/google/cloud/bigtable/admin/v2/doc/google/bigtable/admin/v2/table.rb
207
207
  - lib/google/cloud/bigtable/admin/v2/doc/google/iam/v1/iam_policy.rb
208
+ - lib/google/cloud/bigtable/admin/v2/doc/google/iam/v1/options.rb
208
209
  - lib/google/cloud/bigtable/admin/v2/doc/google/iam/v1/policy.rb
209
210
  - lib/google/cloud/bigtable/admin/v2/doc/google/longrunning/operations.rb
210
211
  - lib/google/cloud/bigtable/admin/v2/doc/google/protobuf/any.rb