Ksql: Introduce a 'CASCADE' like keyword to enable efficient dropping of streams and tables.

Created on 2 Nov 2018  路  5Comments  路  Source: confluentinc/ksql

eg:

str1

create stream str1 as select col1 from  generic_stream;

str2:

create stream str2 as select col1 from str1 where ....

I need terminate str1_query_id and str2_query_id ,and drop str2 & str1

How to fast drop this stream,like Database cascade.

Thanks.

enhancement

Most helpful comment

I'm not sure this is a duplicate of #1317. This is about cascading the delete of a hierarchy of streams, where as #1317 is about automatically terminating queries under a stream.

All 5 comments

We don't have a CASCADE function right now as we think that it is better to require explicit termination and deletion since there is a possibility for losing data.

I'll mark this as an enhancement request.

Now,How to fast drop table & stream in KSQL?

stream1...>...stream2....>...stream3...>...streamN dependent each others.
eg:
I drop stream1; need terminate stream2 and drop stream2
I drop stream2 need terminate stream3 and drop stream3
.....
I drop streamN; need terminate streamN-1 and drop streamN-1

Duplicate of #1317 - please upvote/comment there. Thanks.

I'm not sure this is a duplicate of #1317. This is about cascading the delete of a hierarchy of streams, where as #1317 is about automatically terminating queries under a stream.

+1 from an offline discussion with a user

Was this page helpful?
0 / 5 - 0 ratings