Skip to content

Commit f26c540

Browse files
authored
Remove unnecessary api from MemTable (#6861)
1 parent d610a9f commit f26c540

2 files changed

Lines changed: 2 additions & 19 deletions

File tree

datafusion/core/src/datasource/memory.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,8 @@ impl TableProvider for MemTable {
169169
let inner_vec = arc_inner_vec.read().await;
170170
partitions.push(inner_vec.clone())
171171
}
172-
Ok(Arc::new(MemoryExec::try_new_owned_data(
173-
partitions,
172+
Ok(Arc::new(MemoryExec::try_new(
173+
&partitions,
174174
self.schema(),
175175
projection.cloned(),
176176
)?))

datafusion/core/src/physical_plan/memory.rs

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -151,23 +151,6 @@ impl MemoryExec {
151151
})
152152
}
153153

154-
/// Create a new execution plan for reading in-memory record batches
155-
/// The provided `schema` should not have the projection applied.
156-
pub fn try_new_owned_data(
157-
partitions: Vec<Vec<RecordBatch>>,
158-
schema: SchemaRef,
159-
projection: Option<Vec<usize>>,
160-
) -> Result<Self> {
161-
let projected_schema = project_schema(&schema, projection.as_ref())?;
162-
Ok(Self {
163-
partitions,
164-
schema,
165-
projected_schema,
166-
projection,
167-
sort_information: None,
168-
})
169-
}
170-
171154
/// Set sort information
172155
pub fn with_sort_information(
173156
mut self,

0 commit comments

Comments
 (0)