MCPcopy Create free account
hub / github.com/apache/datafusion / hash_join_yields

Function hash_join_yields

datafusion/core/tests/execution/coop.rs:703–730  ·  view source on GitHub ↗
(
    #[values(false, true)] pretend_infinite: bool,
)

Source from the content-addressed store, hash-verified

701#[rstest]
702#[tokio::test]
703async fn hash_join_yields(
704 #[values(false, true)] pretend_infinite: bool,
705) -> Result<(), Box<dyn Error>> {
706 // build session
707 let session_ctx = SessionContext::new();
708
709 // set up the join sources
710 let inf1 = Arc::new(make_lazy_exec("value1", pretend_infinite));
711 let inf2 = Arc::new(make_lazy_exec("value2", pretend_infinite));
712
713 // set up a HashJoinExec that will take a long time in the build phase
714 let join = Arc::new(HashJoinExec::try_new(
715 inf1.clone(),
716 inf2.clone(),
717 vec![(
718 col("value1", &inf1.schema())?,
719 col("value2", &inf2.schema())?,
720 )],
721 None,
722 &JoinType::Left,
723 None,
724 PartitionMode::CollectLeft,
725 NullEquality::NullEqualsNull,
726 false,
727 )?);
728
729 query_yields(join, session_ctx.task_ctx()).await
730}
731
732#[rstest]
733#[tokio::test]

Callers

nothing calls this directly

Calls 5

newFunction · 0.85
make_lazy_execFunction · 0.85
query_yieldsFunction · 0.85
cloneMethod · 0.45
task_ctxMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…