Skip to main content

Manage Stream

List Streams

SHOW STREAMS

Describe a stream

SHOW CREATE <stream>

ALTER STREAM

Currently we don't recommend to alter the schema of streams in Proton. The only exception is you can modify the retention policy for historical store.

MODIFY TTL

You can add or modify the retention policy. e.g.

ALTER STREAM stream_name MODIFY TTL to_datetime(created_at) + INTERVAL 48 HOUR

DROP STREAM

Run the following SQL to drop a stream or an external stream, with all data in streaming storage and historical storage.

DROP STREAM [IF EXISTS] db.<stream_name>;

Like CREATE STREAM, stream deletion is an async process.

note for Timeplus Cloud users

In Timeplus Cloud or Private Cloud deployments, we recommend you to drop streams with GUI or Terraform Provider, to better tracking the lineage and permission.