changgyoopark-db commented on code in PR #48745:
URL: https://github.com/apache/spark/pull/48745#discussion_r1827490570
##########
connector/connect/server/src/main/scala/org/apache/spark/sql/connect/service/SparkConnectReattachExecuteHandler.scala:
##########
@@ -30,8 +30,10 @@ class SparkConnectReattachExecuteHandler(
def handle(v: proto.ReattachExecuteRequest): Unit = {
// An exception will be raised if the session is not available.
- val _sessionHolder =
+ val sessionHolder =
SparkConnectService.getIsolatedSession(v.getUserContext.getUserId,
v.getSessionId)
+ assert(sessionHolder != null)
Review Comment:
Being pedantic - the compiler might remove _sessionHolder entirely as part
of dead code elimination; adding an assertion shall prevent the compiler from
doing so.
--
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]