Skip to content

Conversation

@BowenXiao1999
Copy link
Contributor

@BowenXiao1999 BowenXiao1999 commented Mar 16, 2022

What's changed and what's your intention?

Part of #967

Checklist

  • I have written necessary docs and comments
  • I have added necessary unit tests and integration tests

Refer to a related PR or issue link (optional)

Copy link
Contributor

Choose a reason for hiding this comment

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

I'd prefer to return Result here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's Ok. The problem is to_stream_prost_body is not return a Result. So there must a unwrap remain.

Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should refactor it to return a Result. I'll take this later. We can unwrap for now.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Why? I think to_prost must succeed.

Copy link
Contributor

Choose a reason for hiding this comment

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

EncodeError always indicates that a message failed to encode because the provided buffer had insufficient capacity. Message encoding is otherwise infallible.

You're right. It must succeed in our cases.

Copy link
Collaborator

Choose a reason for hiding this comment

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

But it's been changed to Result<Vec<ProstField>>😇

Copy link
Contributor

Choose a reason for hiding this comment

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

unreachable?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually not unreachable, if it is Any or AnyShard, it will panic in above match arms. If it's Single/Broadcast, return a zero vector is expected.

@codecov
Copy link

codecov bot commented Mar 16, 2022

Codecov Report

Merging #967 (0ae973b) into main (f8105af) will decrease coverage by 0.04%.
The diff coverage is 0.00%.

@@             Coverage Diff              @@
##               main     #967      +/-   ##
============================================
- Coverage     71.73%   71.69%   -0.05%     
  Complexity     2766     2766              
============================================
  Files           971      972       +1     
  Lines         56825    56938     +113     
  Branches       1787     1787              
============================================
+ Hits          40766    40820      +54     
- Misses        15169    15228      +59     
  Partials        890      890              
Flag Coverage Δ
java 61.23% <ø> (ø)
rust 75.69% <0.00%> (-0.08%) ⬇️

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

Impacted Files Coverage Δ
rust/common/src/catalog/schema.rs 77.55% <0.00%> (-5.06%) ⬇️
...rontend/src/optimizer/plan_node/stream_exchange.rs 0.00% <0.00%> (ø)
...ream/src/executor/managed_state/aggregation/mod.rs 76.59% <0.00%> (-3.41%) ⬇️
rust/storage/src/hummock/error.rs 19.04% <0.00%> (-2.01%) ⬇️
rust/storage/src/hummock/local_version_manager.rs 91.00% <0.00%> (-1.79%) ⬇️
rust/meta/src/manager/catalog.rs 72.98% <0.00%> (-0.55%) ⬇️
rust/utils/logging/src/lib.rs 0.00% <0.00%> (ø)
rust/storage/src/hummock/mod.rs 58.77% <0.00%> (ø)
rust/frontend/src/optimizer/mod.rs 96.15% <0.00%> (ø)
rust/meta/src/hummock/compaction.rs 81.56% <0.00%> (ø)
... and 4 more

📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

@BowenXiao1999 BowenXiao1999 force-pushed the bw_add_stream_exchange branch from 4655b13 to 0ae973b Compare March 16, 2022 06:51
@skyzh skyzh merged commit 3912036 into main Mar 16, 2022
@skyzh skyzh deleted the bw_add_stream_exchange branch March 16, 2022 07:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type/feature Type: New feature.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants