Skip to content
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(optimizer): change stream join mv distribution key #13022

Merged
merged 7 commits into from
Oct 24, 2023

Conversation

chenzl25
Copy link
Contributor

I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.

What's changed and what's your intention?

Checklist

  • I have written necessary rustdoc comments
  • I have added necessary unit tests and integration tests
  • I have added fuzzing tests or opened an issue to track them. (Optional, recommended for new SQL features Sqlsmith: Sql feature generation #7934).
  • My PR contains breaking changes. (If it deprecates some features, please create a tracking issue to remove them in the future).
  • All checks passed in ./risedev check (or alias, ./risedev c)
  • My PR changes performance-critical code. (Please run macro/micro-benchmarks and show the results.)
  • My PR contains critical fixes that are necessary to be merged into the latest release. (Please check out the details)

Documentation

  • My PR needs documentation updates. (Please use the Release note section below to summarize the impact on users)

Release note

If this PR includes changes that directly affect users or other significant modifications relevant to the community, kindly draft a release note to provide a concise summary of these changes. Please prioritize highlighting the impact these changes will have on users.

@fuyufjh
Copy link
Member

fuyufjh commented Oct 24, 2023

Sorry, can you take a look on #12824 (comment)

@chenzl25
Copy link
Contributor Author

Sorry, can you take a look on #12824 (comment)

Currently, we just have stream_key. After we have the unique_key property we can change the distribution to it. It would be more elegant I think.

@fuyufjh
Copy link
Member

fuyufjh commented Oct 24, 2023

Sorry, can you take a look on #12824 (comment)

Currently, we just have stream_key. After we have the unique_key property we can change the distribution to it. It would be more elegant I think.

Okay. Make sense to me.

But unique_key sounds ambiguous with the unique key in relation DB. Even though sharing some similarity, they seem to be different things to me.

Copy link
Member

@fuyufjh fuyufjh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code LGTM.

Needs to run a benchmark test before merging.

@chenzl25
Copy link
Contributor Author

But unique_key sounds ambiguous with the unique key in relation DB. Even though sharing some similarity, they seem to be different things to me.

The unique_key should be exactly what it means in a relational Database. While stream_key is also a unique key, it might contain more redundant columns.

@chenzl25 chenzl25 enabled auto-merge October 24, 2023 12:03
@chenzl25 chenzl25 added this pull request to the merge queue Oct 24, 2023
@codecov
Copy link

codecov bot commented Oct 24, 2023

Codecov Report

Merging #13022 (117fdde) into main (e64543f) will increase coverage by 0.06%.
Report is 2 commits behind head on main.
The diff coverage is 91.66%.

@@            Coverage Diff             @@
##             main   #13022      +/-   ##
==========================================
+ Coverage   68.63%   68.70%   +0.06%     
==========================================
  Files        1495     1495              
  Lines      251135   251145      +10     
==========================================
+ Hits       172369   172548     +179     
+ Misses      78766    78597     -169     
Flag Coverage Δ
rust 68.70% <91.66%> (+0.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
...tend/src/optimizer/plan_node/stream_materialize.rs 97.43% <100.00%> (+0.10%) ⬆️
...rc/frontend/src/optimizer/property/distribution.rs 76.23% <100.00%> (ø)
src/storage/src/hummock/file_cache/store.rs 40.49% <0.00%> (-0.17%) ⬇️

... and 20 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Merged via the queue into main with commit e818508 Oct 24, 2023
10 of 11 checks passed
@chenzl25 chenzl25 deleted the dylan/change_stream_join_mv_distributioin_key branch October 24, 2023 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Discussion: use stream_key as MV's distribution key
2 participants