-
Notifications
You must be signed in to change notification settings - Fork 590
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Experimentally introducing sink into table #13185
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
shanicky
force-pushed
the
peng/sink-into-table-new
branch
3 times, most recently
from
November 3, 2023 10:27
da882e9
to
d6575ba
Compare
shanicky
force-pushed
the
peng/sink-into-table-new
branch
3 times, most recently
from
November 7, 2023 11:33
7f69aad
to
0206548
Compare
shanicky
changed the title
feat: sink into table
feat: Experimentally introducing sink into table
Nov 7, 2023
shanicky
force-pushed
the
peng/sink-into-table-new
branch
5 times, most recently
from
November 13, 2023 07:38
463fedb
to
f2d9b4c
Compare
yezizp2012
reviewed
Nov 14, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rest of meta part generally LGTM.
src/meta/src/rpc/ddl_controller.rs
Outdated
.prepare_replace_table(table_stream_job, table_fragment_graph) | ||
.await?; | ||
|
||
let sink_fragment = sink_table_fragments.sink_fragment().unwrap(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add some assertion for some frontend work.
shanicky
force-pushed
the
peng/new-table-dag
branch
from
November 14, 2023 09:09
e5af73b
to
0b87816
Compare
shanicky
force-pushed
the
peng/sink-into-table-new
branch
3 times, most recently
from
November 14, 2023 09:57
a44e7c5
to
eaabdc2
Compare
shanicky
force-pushed
the
peng/new-table-dag
branch
2 times, most recently
from
November 15, 2023 07:27
5059920
to
9a89780
Compare
fix conflict Signed-off-by: Shanicky Chen <[email protected]>
…ved. add extract_replace_table_info add handle for combined add vistor Update documentation and imports for clarity and functionality. Renamed struct `ReplaceTableCommand` to `ReplaceTablePlan`, along with updates in multiple files. Added assertions for empty incoming sinks and length check for incoming sinks. Removed code for restoring previous incoming sinks. Refactor module, remove function and struct, utilize new trait Add version variable, update its value, return in certain scenarios add check for sink into table dependency Signed-off-by: Shanicky Chen <[email protected]>
… duplicate `DdlProgress` import.
…nd `incoming_sinks` field, removed `visit_stream_node_cont` function.
…n barrier/command.rs, reformat code in rpc/ddl_controller.rs.
… and catalog/mod.rs tmp fix conlict Signed-off-by: Shanicky Chen <[email protected]>
Signed-off-by: Shanicky Chen <[email protected]>
Signed-off-by: Shanicky Chen <[email protected]>
…date function signatures and variable usage.
Signed-off-by: Shanicky Chen <[email protected]>
Signed-off-by: Shanicky Chen <[email protected]>
Signed-off-by: Shanicky Chen <[email protected]>
shanicky
force-pushed
the
peng/sink-into-table-new
branch
from
December 9, 2023 16:01
1478dd3
to
0a05844
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
This PR depends on #12240 and #12495
This PR attempts to introduce the sink into table feature.
Following PR #12240, all newly created tables come with a union operator used to aggregate source/dml and the current sink into table. According to the rfc, we create various structures of sink under these three types.
The specific method is very rudimentary. Currently, when we create a streaming job, we will have an
affected_table_change
, which describes the target table that needs to replace the table. The generated command carries both add and update semantics at this time. We tried to use the combined mutation in PR #12495 to perform this process atomically, but it seems that it may not be necessary, so we may delete this mutation after testing.Mainly, we still have many restrictions that need to be solved in the future:
The first case, table with row id as the primary key.
table
sink
The second case, append only table
table
sink
The third case,table with primary key
table
sink
Checklist
./risedev check
(or alias,./risedev c
)