comphead commented on code in PR #11218:
URL: https://github.com/apache/datafusion/pull/11218#discussion_r1676518816
##########
datafusion/core/tests/memory_limit/mod.rs:
##########
@@ -182,6 +182,24 @@ async fn merge_join() {
.await
}
+#[tokio::test]
+async fn sort_merge_join_spill() {
+ // Planner chooses MergeJoin only if number of partitions > 1
+ let config = SessionConfig::new()
+ .with_target_partitions(2)
+ .set_bool("datafusion.optimizer.prefer_hash_join", false);
+
+ TestCase::new()
+ .with_query(
+ "select t1.* from t t1 JOIN t t2 ON t1.pod = t2.pod AND t1.time =
t2.time",
+ )
+ .with_memory_limit(1_000)
+ .with_config(config)
+ .with_disk_manager_config(DiskManagerConfig::NewOs)
+ .run()
+ .await
Review Comment:
@viirya I added metrics tests in `sort_merge_join.rs` like
https://github.com/apache/datafusion/pull/11218/files#diff-825342e035aec56595dce761afb00dd54e3ae663a2e24ebf3a597123e636f9e2R3140
For this exact test which runs on SQL level I'm thinking if I can access
metrics some how
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]