Skip to content

Apache DataFusion SQL Query Engine

ARROW-12136: [Rust][DataFusion] Reduce default batch_size to 8192

Heres, Daniel14fb714001d5
diff --git a/rust/benchmarks/src/bin/nyctaxi.rs b/rust/benchmarks/src/bin/nyctaxi.rs
index 3391c38c8d..005efca948 100644
--- a/rust/benchmarks/src/bin/nyctaxi.rs
+++ b/rust/benchmarks/src/bin/nyctaxi.rs
@@ -51,7 +51,7 @@ struct Opt {
concurrency: usize,
/// Batch size when reading CSV or Parquet files
- #[structopt(short = "s", long = "batch-size", default_value = "4096")]
+ #[structopt(short = "s", long = "batch-size", default_value = "8192")]
batch_size: usize,
/// Path to data files
diff --git a/rust/benchmarks/src/bin/tpch.rs b/rust/benchmarks/src/bin/tpch.rs
index 0a1ef0b6a7..46f4516da1 100644
--- a/rust/benchmarks/src/bin/tpch.rs
+++ b/rust/benchmarks/src/bin/tpch.rs
@@ -63,7 +63,7 @@ struct BenchmarkOpt {
concurrency: usize,
/// Batch size when reading CSV or Parquet files
- #[structopt(short = "s", long = "batch-size", default_value = "32768")]
+ #[structopt(short = "s", long = "batch-size", default_value = "8192")]
batch_size: usize,
/// Path to data files
@@ -106,7 +106,7 @@ struct ConvertOpt {
partitions: usize,
/// Batch size when reading CSV or Parquet files
- #[structopt(short = "s", long = "batch-size", default_value = "4096")]
+ #[structopt(short = "s", long = "batch-size", default_value = "8192")]
batch_size: usize,
}
@@ -1658,7 +1658,7 @@ mod tests {
debug: false,
iterations: 1,
concurrency: 2,
- batch_size: 4096,
+ batch_size: 8192,
path: PathBuf::from(path.to_string()),
file_format: "tbl".to_string(),
mem_table: false,
diff --git a/rust/datafusion/src/execution/context.rs b/rust/datafusion/src/execution/context.rs
index 01f4204dba..3bbe02b5b5 100644
--- a/rust/datafusion/src/execution/context.rs
+++ b/rust/datafusion/src/execution/context.rs
@@ -586,7 +586,7 @@ impl ExecutionConfig {
pub fn new() -> Self {
Self {
concurrency: num_cpus::get(),
- batch_size: 32768,
+ batch_size: 8192,
optimizers: vec![
Arc::new(ConstantFolding::new()),
Arc::new(ProjectionPushDown::new()),