Skip to main content
When creating a source, you can choose to persist the data from the source in RisingWave by using CREATE TABLE instead of CREATE SOURCE and specifying the connection settings and data format.

Syntax

schema_definition:
For Avro and Protobuf data, do not specify schema_definition in the CREATE SOURCE or CREATE TABLE statement. The schema should be provided in a Web location in the option schema.location in ENCODE properties section.
RisingWave performs primary key constraint checks on tables with connector settings but not on regular sources. If you need the checks to be performed, please create a table with connector settings. For a table with primary key constraints, if a new data record with an existing key comes in, the new record will overwrite the existing record.

Connector parameters

Other parameters

Read schemas from locations

RisingWave supports reading schemas from a Web location in http://..., https://..., or S3://... format for Pulsar data in Avro or Protobuf format. For Protobuf, if a schema location is specified, the schema file must be a FileDescriptorSet, which can be compiled from a .proto file with a command like this:
To specify a schema location, add this clause to a CREATE SOURCE statement.
If a primary key also needs to be defined, use the table constraint syntax.

Example

Here is an example of connecting RisingWave to a Pulsar broker to read data from individual topics.