google-cloud-bigquery 1.51.0 → 1.51.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/google/cloud/bigquery/dataset.rb +3 -2
- data/lib/google/cloud/bigquery/service.rb +7 -4
- data/lib/google/cloud/bigquery/table/async_inserter.rb +2 -1
- data/lib/google/cloud/bigquery/table.rb +2 -1
- data/lib/google/cloud/bigquery/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 22622b84cc452512e75c5ac091f5e71984f0832756f019c4db07b7a65630548d
|
4
|
+
data.tar.gz: 80e428c51bac81fcd01a5cd05be6524fadfede36242f6d0803aa20eaa00c3529
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 321176420b19fc2ffc9f49deb73d0445835d8a89842e82fb9f63d3420332ce6f93a9d3c17cc4fb601d11721dd998268214ef39e7fd9eedda17e6afd1fcf9e973
|
7
|
+
data.tar.gz: f16ab1999e2a3b8aeeb79072c7cbe36db0388550a11c0afed6a1774a6bcda02a9aba72f45ddb29cced5520a804008248b1656f3ddd92320c40b35590da623972
|
data/CHANGELOG.md
CHANGED
@@ -2810,7 +2810,7 @@ module Google
|
|
2810
2810
|
ensure_service!
|
2811
2811
|
|
2812
2812
|
# Get table, don't use Dataset#table which handles NotFoundError
|
2813
|
-
gapi = service.
|
2813
|
+
gapi = service.get_project_table project_id, dataset_id, table_id, metadata_view: view
|
2814
2814
|
table = Table.from_gapi gapi, service, metadata_view: view
|
2815
2815
|
# Get the AsyncInserter from the table
|
2816
2816
|
table.insert_async skip_invalid: skip_invalid,
|
@@ -2865,7 +2865,8 @@ module Google
|
|
2865
2865
|
ensure_service!
|
2866
2866
|
gapi = service.insert_tabledata dataset_id, table_id, rows, skip_invalid: skip_invalid,
|
2867
2867
|
ignore_unknown: ignore_unknown,
|
2868
|
-
insert_ids: insert_ids
|
2868
|
+
insert_ids: insert_ids,
|
2869
|
+
project_id: project_id
|
2869
2870
|
InsertResponse.from_gapi rows, gapi
|
2870
2871
|
end
|
2871
2872
|
|
@@ -257,15 +257,17 @@ module Google
|
|
257
257
|
end
|
258
258
|
end
|
259
259
|
|
260
|
-
def insert_tabledata dataset_id, table_id, rows, insert_ids: nil, ignore_unknown: nil,
|
260
|
+
def insert_tabledata dataset_id, table_id, rows, insert_ids: nil, ignore_unknown: nil,
|
261
|
+
skip_invalid: nil, project_id: nil
|
261
262
|
json_rows = Array(rows).map { |row| Convert.to_json_row row }
|
262
263
|
insert_tabledata_json_rows dataset_id, table_id, json_rows, insert_ids: insert_ids,
|
263
264
|
ignore_unknown: ignore_unknown,
|
264
|
-
skip_invalid: skip_invalid
|
265
|
+
skip_invalid: skip_invalid,
|
266
|
+
project_id: project_id
|
265
267
|
end
|
266
268
|
|
267
269
|
def insert_tabledata_json_rows dataset_id, table_id, json_rows, insert_ids: nil, ignore_unknown: nil,
|
268
|
-
skip_invalid: nil
|
270
|
+
skip_invalid: nil, project_id: nil
|
269
271
|
rows_and_ids = Array(json_rows).zip Array(insert_ids)
|
270
272
|
insert_rows = rows_and_ids.map do |json_row, insert_id|
|
271
273
|
if insert_id == :skip
|
@@ -286,9 +288,10 @@ module Google
|
|
286
288
|
}.to_json
|
287
289
|
|
288
290
|
# The insertAll with insertId operation is considered idempotent
|
291
|
+
project_id ||= @project
|
289
292
|
execute backoff: true do
|
290
293
|
service.insert_all_table_data(
|
291
|
-
|
294
|
+
project_id, dataset_id, table_id, insert_req,
|
292
295
|
options: { skip_serialization: true }
|
293
296
|
)
|
294
297
|
end
|
@@ -294,7 +294,8 @@ module Google
|
|
294
294
|
json_rows,
|
295
295
|
skip_invalid: @skip_invalid,
|
296
296
|
ignore_unknown: @ignore_unknown,
|
297
|
-
insert_ids: insert_ids
|
297
|
+
insert_ids: insert_ids,
|
298
|
+
project_id: @table.project_id
|
298
299
|
|
299
300
|
result = Result.new InsertResponse.from_gapi(orig_rows, insert_resp)
|
300
301
|
rescue StandardError => e
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-bigquery
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.51.
|
4
|
+
version: 1.51.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Moore
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2024-12-
|
12
|
+
date: 2024-12-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bigdecimal
|
@@ -189,7 +189,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
189
189
|
- !ruby/object:Gem::Version
|
190
190
|
version: '0'
|
191
191
|
requirements: []
|
192
|
-
rubygems_version: 3.5.
|
192
|
+
rubygems_version: 3.5.23
|
193
193
|
signing_key:
|
194
194
|
specification_version: 4
|
195
195
|
summary: API Client library for Google BigQuery
|