Skip to content
This repository was archived by the owner on Feb 24, 2026. It is now read-only.

Commit 357e811

Browse files
feat: new JSON type through BigQuery Write (#1013)
Committer: @yirutang PiperOrigin-RevId: 368275477 Source-Author: Google APIs <noreply@google.com> Source-Date: Tue Apr 13 12:51:14 2021 -0700 Source-Repo: googleapis/googleapis Source-Sha: 95e7f055087a43f638ffd9a0f25ce36dbea87953 Source-Link: googleapis/googleapis@95e7f05
1 parent a55aded commit 357e811

File tree

4 files changed

+40
-23
lines changed

4 files changed

+40
-23
lines changed

proto-google-cloud-bigquerystorage-v1beta2/src/main/java/com/google/cloud/bigquery/storage/v1beta2/TableFieldSchema.java

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,16 @@ public enum Type implements com.google.protobuf.ProtocolMessageEnum {
306306
* <code>INTERVAL = 14;</code>
307307
*/
308308
INTERVAL(14),
309+
/**
310+
*
311+
*
312+
* <pre>
313+
* JSON, String
314+
* </pre>
315+
*
316+
* <code>JSON = 15;</code>
317+
*/
318+
JSON(15),
309319
UNRECOGNIZED(-1),
310320
;
311321

@@ -459,6 +469,16 @@ public enum Type implements com.google.protobuf.ProtocolMessageEnum {
459469
* <code>INTERVAL = 14;</code>
460470
*/
461471
public static final int INTERVAL_VALUE = 14;
472+
/**
473+
*
474+
*
475+
* <pre>
476+
* JSON, String
477+
* </pre>
478+
*
479+
* <code>JSON = 15;</code>
480+
*/
481+
public static final int JSON_VALUE = 15;
462482

463483
public final int getNumber() {
464484
if (this == UNRECOGNIZED) {
@@ -514,6 +534,8 @@ public static Type forNumber(int value) {
514534
return BIGNUMERIC;
515535
case 14:
516536
return INTERVAL;
537+
case 15:
538+
return JSON;
517539
default:
518540
return null;
519541
}

proto-google-cloud-bigquerystorage-v1beta2/src/main/java/com/google/cloud/bigquery/storage/v1beta2/TableProto.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,25 +49,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
4949
+ "ge.v1beta2\032\037google/api/field_behavior.pr"
5050
+ "oto\"V\n\013TableSchema\022G\n\006fields\030\001 \003(\01327.goo"
5151
+ "gle.cloud.bigquery.storage.v1beta2.Table"
52-
+ "FieldSchema\"\305\004\n\020TableFieldSchema\022\021\n\004name"
52+
+ "FieldSchema\"\317\004\n\020TableFieldSchema\022\021\n\004name"
5353
+ "\030\001 \001(\tB\003\340A\002\022O\n\004type\030\002 \001(\0162<.google.cloud"
5454
+ ".bigquery.storage.v1beta2.TableFieldSche"
5555
+ "ma.TypeB\003\340A\002\022O\n\004mode\030\003 \001(\0162<.google.clou"
5656
+ "d.bigquery.storage.v1beta2.TableFieldSch"
5757
+ "ema.ModeB\003\340A\001\022L\n\006fields\030\004 \003(\01327.google.c"
5858
+ "loud.bigquery.storage.v1beta2.TableField"
59-
+ "SchemaB\003\340A\001\022\030\n\013description\030\006 \001(\tB\003\340A\001\"\313\001"
59+
+ "SchemaB\003\340A\001\022\030\n\013description\030\006 \001(\tB\003\340A\001\"\325\001"
6060
+ "\n\004Type\022\024\n\020TYPE_UNSPECIFIED\020\000\022\n\n\006STRING\020\001"
6161
+ "\022\t\n\005INT64\020\002\022\n\n\006DOUBLE\020\003\022\n\n\006STRUCT\020\004\022\t\n\005B"
6262
+ "YTES\020\005\022\010\n\004BOOL\020\006\022\r\n\tTIMESTAMP\020\007\022\010\n\004DATE\020"
6363
+ "\010\022\010\n\004TIME\020\t\022\014\n\010DATETIME\020\n\022\r\n\tGEOGRAPHY\020\013"
6464
+ "\022\013\n\007NUMERIC\020\014\022\016\n\nBIGNUMERIC\020\r\022\014\n\010INTERVA"
65-
+ "L\020\016\"F\n\004Mode\022\024\n\020MODE_UNSPECIFIED\020\000\022\014\n\010NUL"
66-
+ "LABLE\020\001\022\014\n\010REQUIRED\020\002\022\014\n\010REPEATED\020\003B\207\001\n)"
67-
+ "com.google.cloud.bigquery.storage.v1beta"
68-
+ "2B\nTableProtoP\001ZLgoogle.golang.org/genpr"
69-
+ "oto/googleapis/cloud/bigquery/storage/v1"
70-
+ "beta2;storageb\006proto3"
65+
+ "L\020\016\022\010\n\004JSON\020\017\"F\n\004Mode\022\024\n\020MODE_UNSPECIFIE"
66+
+ "D\020\000\022\014\n\010NULLABLE\020\001\022\014\n\010REQUIRED\020\002\022\014\n\010REPEA"
67+
+ "TED\020\003B\207\001\n)com.google.cloud.bigquery.stor"
68+
+ "age.v1beta2B\nTableProtoP\001ZLgoogle.golang"
69+
+ ".org/genproto/googleapis/cloud/bigquery/"
70+
+ "storage/v1beta2;storageb\006proto3"
7171
};
7272
descriptor =
7373
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(

proto-google-cloud-bigquerystorage-v1beta2/src/main/proto/google/cloud/bigquery/storage/v1beta2/table.proto

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,9 @@ message TableFieldSchema {
7676

7777
// Interval
7878
INTERVAL = 14;
79+
80+
// JSON, String
81+
JSON = 15;
7982
}
8083

8184
enum Mode {

synth.metadata

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,39 +11,31 @@
1111
"git": {
1212
"name": ".",
1313
"remote": "https://github.com/googleapis/java-bigquerystorage.git",
14-
"sha": "42298848f5511cca98ffe04ac370e6760856b555"
14+
"sha": "cc243d97a14df3c94133b0705d6e5d5ef92a8286"
1515
}
1616
},
1717
{
1818
"git": {
1919
"name": "googleapis",
2020
"remote": "https://github.com/googleapis/googleapis.git",
21-
"sha": "86c2fe6229f16e0f113a4cf9edea35d71895a6a6",
22-
"internalRef": "367652775"
21+
"sha": "95e7f055087a43f638ffd9a0f25ce36dbea87953",
22+
"internalRef": "368275477"
2323
}
2424
},
2525
{
2626
"git": {
2727
"name": "googleapis",
2828
"remote": "https://github.com/googleapis/googleapis.git",
29-
"sha": "86c2fe6229f16e0f113a4cf9edea35d71895a6a6",
30-
"internalRef": "367652775"
29+
"sha": "95e7f055087a43f638ffd9a0f25ce36dbea87953",
30+
"internalRef": "368275477"
3131
}
3232
},
3333
{
3434
"git": {
3535
"name": "googleapis",
3636
"remote": "https://github.com/googleapis/googleapis.git",
37-
"sha": "86c2fe6229f16e0f113a4cf9edea35d71895a6a6",
38-
"internalRef": "367652775"
39-
}
40-
},
41-
{
42-
"git": {
43-
"name": "googleapis",
44-
"remote": "https://github.com/googleapis/googleapis.git",
45-
"sha": "86c2fe6229f16e0f113a4cf9edea35d71895a6a6",
46-
"internalRef": "367652775"
37+
"sha": "95e7f055087a43f638ffd9a0f25ce36dbea87953",
38+
"internalRef": "368275477"
4739
}
4840
},
4941
{

0 commit comments

Comments
 (0)