cloud-fan commented on a change in pull request #30575:
URL: https://github.com/apache/spark/pull/30575#discussion_r535080636
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
##########
@@ -98,13 +98,15 @@ object FakeV2SessionCatalog extends TableCatalog {
* views.
* @param nestedViewDepth The nested depth in the view resolution, this
enables us to limit the
* depth of nested views.
+ * @param maxNestedViewDepth The maximum allowed depth of nested view
resolution.
* @param relationCache A mapping from qualified table names to resolved
relations. This can ensure
* that the table is resolved only once if a table is
used multiple times
* in a query.
*/
case class AnalysisContext(
catalogAndNamespace: Seq[String] = Nil,
nestedViewDepth: Int = 0,
+ maxNestedViewDepth: Int = SQLConf.get.maxNestedViewDepth,
Review comment:
The initial value is created with `AnalysisContext()`, so
`maxNestedViewDepth` starts with the configured value. For nested view
resolution, we create new contexts with `withAnalysisContext`, which retain the
value of `maxNestedViewDepth`
----------------------------------------------------------------
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]