Skip to content

Commit

Permalink
remove Send requirement on R prameter for VortexRecordBatchReader
Browse files Browse the repository at this point in the history
  • Loading branch information
danking committed Oct 18, 2024
1 parent f9f6662 commit 5b6b12a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions vortex-serde/src/layouts/read/recordbatchreader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ fn vortex_to_arrow(result: VortexResult<Array>) -> Result<RecordBatch, ArrowErro
.map_err(vortex_to_arrow_error)
}

pub struct VortexRecordBatchReader<R: VortexReadAt + Unpin + Send + 'static> {
pub struct VortexRecordBatchReader<R: VortexReadAt + Unpin + 'static> {
stream: LayoutBatchStream<R>,
arrow_schema: SchemaRef,
}

impl<R: VortexReadAt + Unpin + Send + 'static> VortexRecordBatchReader<R> {
impl<R: VortexReadAt + Unpin + 'static> VortexRecordBatchReader<R> {
pub fn new(stream: LayoutBatchStream<R>) -> VortexResult<VortexRecordBatchReader<R>> {
let arrow_schema = Arc::new(infer_schema(stream.schema().dtype())?);
Ok(VortexRecordBatchReader {
Expand All @@ -35,7 +35,7 @@ impl<R: VortexReadAt + Unpin + Send + 'static> VortexRecordBatchReader<R> {
}
}

impl<R: VortexReadAt + Unpin + Send + 'static> Iterator for VortexRecordBatchReader<R> {
impl<R: VortexReadAt + Unpin + 'static> Iterator for VortexRecordBatchReader<R> {
type Item = Result<RecordBatch, ArrowError>;

fn next(&mut self) -> Option<Self::Item> {
Expand All @@ -44,7 +44,7 @@ impl<R: VortexReadAt + Unpin + Send + 'static> Iterator for VortexRecordBatchRea
}
}

impl<R: VortexReadAt + Unpin + Send + 'static> RecordBatchReader for VortexRecordBatchReader<R> {
impl<R: VortexReadAt + Unpin + 'static> RecordBatchReader for VortexRecordBatchReader<R> {
fn schema(&self) -> SchemaRef {
self.arrow_schema.clone()
}
Expand Down

0 comments on commit 5b6b12a

Please sign in to comment.