Apache DataFusion SQL Query Engine
Improve benchmark documentation (#15054)
Carol (Nichols || Goulding)13b731c469d0
diff --git a/benchmarks/README.md b/benchmarks/README.mdindex c0bdb1dba7..40d467b5bb 100644--- a/benchmarks/README.md+++ b/benchmarks/README.md@@ -329,7 +329,37 @@ Your benchmark should create and use an instance of `BenchmarkRun` defined in `b# Benchmarks-The output of `dfbench` help includes a description of each benchmark, which is reproduced here for convenience+The output of `dfbench` help includes a description of each benchmark, which is reproduced here for convenience.++## Cancellation++Test performance of cancelling queries+Queries in DataFusion should stop executing "quickly" after they are+cancelled (the output stream is dropped).++The queries are executed on a synthetic dataset generated during+the benchmark execution that is an anonymized version of a+real-world data set.++The query is an anonymized version of a real-world query, and the+test starts the query then cancels it and reports how long it takes+for the runtime to fully exit.++Example output:++```+Using 7 files found on disk+Starting to load data into in-memory object store+Done loading data into in-memory object store+in main, sleeping+Starting spawned+Creating logical plan...+Creating physical plan...+Executing physical plan...+Getting results...+cancelling thread+done dropping runtime in 83.531417ms+```## ClickBenchdiff --git a/benchmarks/src/cancellation.rs b/benchmarks/src/cancellation.rsindex 3c3ca424a3..f5740bdc96 100644--- a/benchmarks/src/cancellation.rs+++ b/benchmarks/src/cancellation.rs@@ -47,6 +47,9 @@ use tokio_util::sync::CancellationToken;/// Test performance of cancelling queries///+/// Queries in DataFusion should stop executing "quickly" after they are+/// cancelled (the output stream is dropped).+////// The queries are executed on a synthetic dataset generated during/// the benchmark execution that is an anonymized version of a/// real-world data set.@@ -97,7 +100,7 @@ impl RunOpt {println!("Done loading data into in-memory object store");let mut rundata = BenchmarkRun::new();- rundata.start_new_case("Arglebargle");+ rundata.start_new_case("Cancellation");for i in 0..self.common.iterations {let elapsed = run_test(self.wait_time, Arc::clone(&store))?;