Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Removed flushing during arrow IPC writing to improve performance when using a buffered writer #1318

Merged
merged 1 commit into from Dec 6, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/io/ipc/write/common_async.rs
Expand Up @@ -48,7 +48,6 @@ pub async fn write_continuation<W: AsyncWrite + Unpin + Send>(
) -> Result<usize> {
writer.write_all(&CONTINUATION_MARKER).await?;
writer.write_all(&total_len.to_le_bytes()[..]).await?;
writer.flush().await?;
Ok(8)
}

Expand All @@ -66,6 +65,5 @@ async fn write_body_buffers<W: AsyncWrite + Unpin + Send>(
writer.write_all(&vec![0u8; pad_len][..]).await?;
}

writer.flush().await?;
Ok(total_len)
}
2 changes: 0 additions & 2 deletions src/io/ipc/write/common_sync.rs
Expand Up @@ -47,7 +47,6 @@ fn write_body_buffers<W: Write>(mut writer: W, data: &[u8]) -> Result<usize> {
writer.write_all(&vec![0u8; pad_len][..])?;
}

writer.flush()?;
Ok(total_len)
}

Expand All @@ -56,6 +55,5 @@ fn write_body_buffers<W: Write>(mut writer: W, data: &[u8]) -> Result<usize> {
pub fn write_continuation<W: Write>(writer: &mut W, total_len: i32) -> Result<usize> {
writer.write_all(&CONTINUATION_MARKER)?;
writer.write_all(&total_len.to_le_bytes()[..])?;
writer.flush()?;
Ok(8)
}