JoshRosen commented on code in PR #37282:
URL: https://github.com/apache/spark/pull/37282#discussion_r929501950
##########
sql/core/src/main/scala/org/apache/spark/sql/util/QueryExecutionListener.scala:
##########
@@ -81,7 +81,10 @@ class ExecutionListenerManager private[sql](
loadExtensions: Boolean)
extends Logging {
- private val listenerBus = new ExecutionListenerBus(this, session)
Review Comment:
Yeah, I was worried about `clone`. Now that I think about it, though, I
think a `lazy val` might be okay: most of the new `SparkSessions` will be child
sessions of the root session, so the work I did in `clone` is only saving a
registration of the root session and isn't saving any work in the child.
Avoiding an unnecessary initialization in clone would only make a difference if
you had a large number of child sessions which spawned large numbers of
grandchildren sessions, but I'm not worried about that case. Let me update to
make it a simple `lazy val`.
--
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]