Conversion

RisingWave converts well-known types from the protobuf library to specific types in RisingWave. The conversion is as follows:

Protobuf typeRisingWave type
anyJSONB
doubledouble precision
floatreal
int32int
int64bigint
uint32bigint
uint64decimal
sint32int
sint64bigint
fixed32bigint
fixed64decimal
sfixed32int
sfixed64bigint
boolboolean
stringvarchar
bytesbytea
enumvarchar
messagestruct. See details in Nested messages.
repeatedarray
mapmap. See details in Map.
google.protobuf.StructNot supported
google.protobuf.Timestampstruct<seconds bigint, nanos int>
google.protobuf.Durationstruct<seconds bigint, nanos int>
google.protobuf.Anystruct<type_url varchar, value bytea>
google.protobuf.Int32Valuestruct<value int>
google.protobuf.StringValuestruct<value varchar>

Nested messages

The nested fields are transformed into columns within a struct type. For example, a Protobuf message with the following structure:

message NestedMessage {
  int32 id = 1;
  string name = 2;
}

Will be converted to struct<id int, name varchar> in RisingWave.