Serializing with Protobuf
Last updated
Last updated
The following table lists the data type mapping from Protobuf type to DeltaStream's Data Types.
INT64, SINT64, SFIXED64, UINT64, FIXED64
BIGINT
BYTES
VARBINARY
BOOL
BOOLEAN
DOUBLE
DOUBLE
FLOAT
FLOAT
INT32, SINT32, SFIXED32, UINT32, FIXED32
INTEGER
STRING, ENUM
VARCHAR
MAP
MAP
MESSAGE
STRUCT
repeated
ARRAY
Note Currently, there is no support for Protobuf types ANY
and OneOf
in serialization. Columns in a or fields in a Struct are strictly typed at the creation time.
There is support for Protobuf's wrapped message types that capture primitive values, in serialization. If the message instance has a valid value set when deserializing, that value is unwrapped to its corresponding primitive type. If there is no value set in the message, that column or Struct field is set to null.
The following table lists the mapping for these types:
google.protobuf.BoolValue
BOOLEAN
google.protobuf.Int32Value
INTEGER
google.protobuf.UInt32Value
INTEGER
google.protobuf.Int64Value
BIGINT
google.protobuf.UInt64Value
BIGINT
google.protobuf.FloatValue
FLOAT
google.protobuf.DoubleValue
DOUBLE
google.protobuf.StringValue
VARCHAR
google.protobuf.BytesValue
VARBINARY
google.protobuf.Timestamp
TIMESTAMP, TIMESTAMP_LTZ