You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "HyukjinKwon (via GitHub)" <gi...@apache.org> on 2026/08/05 08:51:02 UTC

Re: [PR] [CONNECT] Demonstrate stale cached plan without DSv2 refresh [spark]

HyukjinKwon commented on code in PR #57683:
URL: https://github.com/apache/spark/pull/57683#discussion_r3719229451


##########
sql/core/src/main/scala/org/apache/spark/sql/execution/QueryExecution.scala:
##########
@@ -70,7 +70,7 @@ class QueryExecution(
     val tracker: QueryPlanningTracker = new QueryPlanningTracker,
     val mode: CommandExecutionMode.Value = CommandExecutionMode.ALL,
     val shuffleCleanupModeOpt: Option[ShuffleCleanupMode] = None,
-    val refreshPhaseEnabled: Boolean = true,
+    val refreshPhaseEnabled: Boolean = false,

Review Comment:
   This flips the primary-constructor default of refreshPhaseEnabled from true to false, which globally disables the DSv2/metadata refresh phase for every direct new QueryExecution(...) (the phase is gated below at if (refreshPhaseEnabled)). That reintroduces the stale-cached-plan behavior this PR demonstrates, for all callers -- not just the Connect path. The helper factories still default to true, so this also makes direct construction diverge from them. If the intent is only to demonstrate the bug, please keep this default at true and drive the tests via a test-local QueryExecution with refreshPhaseEnabled = false (and mark the PR [WIP]/draft); the actual fix should gate refresh narrowly as in #57609 rather than turning it off by default.



-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org