Skip to content

Commit 634c8c9

Browse files
committed
monolithic
Signed-off-by: Adam Gutglick <adam@spiraldb.com>
1 parent 46f9345 commit 634c8c9

5 files changed

Lines changed: 489 additions & 22 deletions

File tree

vortex-file/src/file.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,10 @@ impl VortexFile {
111111

112112
/// Initiate a scan of the file, returning a builder for configuring the scan.
113113
pub fn scan(&self) -> VortexResult<ScanBuilder<ArrayRef>> {
114-
Ok(ScanBuilder::new(
115-
self.session.clone(),
116-
self.layout_reader()?,
114+
Ok(
115+
ScanBuilder::new(self.session.clone(), self.layout_reader()?)
116+
.with_segment_source(self.segment_source()),
117117
)
118-
.with_segment_source(self.segment_source()))
119118
}
120119

121120
/// Returns true if the expression will never match any rows in the file.

vortex-scan/src/fetch_plan.rs

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,13 @@ mod tests {
336336
fn deferred_plan_activates_for_narrow_filtered_projection() {
337337
let projection = select(["id", "payload"], root());
338338
let mask = vec![FieldMask::Prefix(FieldPath::from(Field::Name("id".into())))];
339-
let plan = MaterializationPlan::from_projection(&projection, &scan_dtype(), true, &mask, &BTreeSet::new());
339+
let plan = MaterializationPlan::from_projection(
340+
&projection,
341+
&scan_dtype(),
342+
true,
343+
&mask,
344+
&BTreeSet::new(),
345+
);
340346
let deferred = plan.deferred().expect("deferred plan");
341347
assert_eq!(
342348
deferred.final_fields(),
@@ -350,22 +356,40 @@ mod tests {
350356
fn deferred_plan_stays_off_for_unfiltered_projection() {
351357
let projection = select(["id", "payload"], root());
352358
let mask = vec![FieldMask::Prefix(FieldPath::from(Field::Name("id".into())))];
353-
let plan = MaterializationPlan::from_projection(&projection, &scan_dtype(), false, &mask, &BTreeSet::new());
359+
let plan = MaterializationPlan::from_projection(
360+
&projection,
361+
&scan_dtype(),
362+
false,
363+
&mask,
364+
&BTreeSet::new(),
365+
);
354366
assert!(plan.deferred().is_none());
355367
}
356368

357369
#[test]
358370
fn deferred_plan_stays_off_for_root_projection() {
359371
let mask = vec![FieldMask::Prefix(FieldPath::from(Field::Name("id".into())))];
360-
let plan = MaterializationPlan::from_projection(&root(), &scan_dtype(), true, &mask, &BTreeSet::new());
372+
let plan = MaterializationPlan::from_projection(
373+
&root(),
374+
&scan_dtype(),
375+
true,
376+
&mask,
377+
&BTreeSet::new(),
378+
);
361379
assert!(plan.deferred().is_none());
362380
}
363381

364382
#[test]
365383
fn deferred_plan_stays_off_for_wide_projection() {
366384
let projection = select(["id", "score", "payload", "nested"], root());
367385
let mask = vec![FieldMask::Prefix(FieldPath::from(Field::Name("id".into())))];
368-
let plan = MaterializationPlan::from_projection(&projection, &scan_dtype(), true, &mask, &BTreeSet::new());
386+
let plan = MaterializationPlan::from_projection(
387+
&projection,
388+
&scan_dtype(),
389+
true,
390+
&mask,
391+
&BTreeSet::new(),
392+
);
369393
assert!(plan.deferred().is_none());
370394
}
371395

0 commit comments

Comments
 (0)