-
Notifications
You must be signed in to change notification settings - Fork 526
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(batch): index scan & point get #3014
Conversation
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.
license-eye has totally checked 826 files.
Valid | Invalid | Ignored | Fixed |
---|---|---|---|
824 | 1 | 1 | 0 |
Click to see the invalid file list
- src/frontend/src/utils/scan_range.rs
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Codecov Report
@@ Coverage Diff @@
## main #3014 +/- ##
==========================================
- Coverage 73.48% 73.40% -0.08%
==========================================
Files 733 734 +1
Lines 99548 99973 +425
==========================================
+ Hits 73157 73390 +233
- Misses 26391 26583 +192
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
#3008 merged. |
Should we make |
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.
license-eye has totally checked 833 files.
Valid | Invalid | Ignored | Fixed |
---|---|---|---|
831 | 1 | 1 | 0 |
Click to see the invalid file list
- src/batch/src/executor/row_seq_scan.rs
Why bother? 🤔 |
@@ -436,7 +442,7 @@ async fn test_row_seq_scan() -> Result<()> { | |||
|
|||
let executor = Box::new(RowSeqScanExecutor::new( | |||
table.schema().clone(), | |||
table.iter_with_pk(u64::MAX, pk_descs).await.unwrap(), | |||
ScanType::TableScan(table.iter_with_pk(u64::MAX, pk_descs).await.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.
Add tests for other ScanType
?
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.
e2e test is enough?
src/frontend/src/utils/scan_range.rs
Outdated
pub eq_conds: Vec<Literal>, | ||
/// ((lb, inclusive), (ub, inclusive)) | ||
#[allow(clippy::type_complexity)] | ||
pub range: Option<(Option<(Literal, bool)>, Option<(Literal, bool)>)>, |
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.
Is it possible to change it to T: Range<Literal>
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.
updated
😕 @BugenZhao Any idea how to fix it? |
And Unbounded in storage not handled correctly 😕 |
finished except excluded start key 😇 |
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.
LGTM!
pk_prefix: &Row, | ||
next_col_bound: Bound<&Datum>, | ||
is_start_bound: bool, | ||
) -> StorageResult<Bound<Vec<u8>>> { |
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.
So it seems unnecessary to return StorageResult<...>
?
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.
serialize_pk returns Result
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.
I think serialize_pk
should not return StorageResult
as well...
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.
Yes it returns Ok 😇 Let's get rid of it
Currently we only implemented some of the bound. If you need exclude bound, use |
included end key -> excluded next key
I feel confused about whether and where to add |
@xxchan Does this PR contain user-facing changes? Thanks. |
This is a perfermance optimization. No behavior changes. |
What's changed and what's your intention?
As title. Mainly added
ScanRange
, which is built inLogicalScan::to_batch
and used inRowSeqScan
for different types of scan.Checklist
./risedev check
(or alias,./risedev c
)Refer to a related PR or issue link (optional)
part of #2429