bojana-db commented on code in PR #57811:
URL: https://github.com/apache/spark/pull/57811#discussion_r3934224150
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/exchange/BroadcastExchangeExec.scala:
##########
Review Comment:
This file doesn't seem properly formatted. Please run `./dev/scalafmt`
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/exchange/BroadcastExchangeExec.scala:
##########
@@ -193,7 +193,14 @@ case class BroadcastExchangeExec(
val beforeBuild = System.nanoTime()
longMetric("collectTime") += NANOSECONDS.toMillis(beforeBuild -
beforeCollect)
- // Construct the relation.
+ mode match {
+ case h: HashedRelationBroadcastMode =>
+ registerSubqueries(h.key)
Review Comment:
`registerSubqueries` mutates the shared `runningSubqueries` buffer but
doesn't hold `prepareLock`. That was fine when its only caller was
prepareSubqueries (which runs under the lock via prepare()). Please guard the
mutation.
--
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]