wzhfy commented on a change in pull request #29589:
URL: https://github.com/apache/spark/pull/29589#discussion_r484684202



##########
File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/SubqueryBroadcastExec.scala
##########
@@ -60,10 +63,12 @@ case class SubqueryBroadcastExec(
   }
 
   @transient
-  private lazy val relationFuture: Future[Array[InternalRow]] = {
+  private lazy val relationFuture: JFuture[Array[InternalRow]] = {
     // relationFuture is used in "doExecute". Therefore we can get the 
execution id correctly here.
     val executionId = 
sparkContext.getLocalProperty(SQLExecution.EXECUTION_ID_KEY)
-    Future {
+    SQLExecution.withThreadLocalCaptured[Array[InternalRow]](

Review comment:
       > I don't think we need a separate config. The thread pool here is used 
to wait for the broadcast to finish, seems better to have same number of slots 
compared to broadcast exchange thread pool.
   
   @cloud-fan  The previous number of subquery broadcast threads is 16, while 
the default number of broadcast exchange threads is 128.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to