Skip to content

Commit 8fcb15d

Browse files
committed
[SPARK-34766][SQL] Do not capture maven config for views
### What changes were proposed in this pull request? Skip capture maven repo config for views. ### Why are the changes needed? Due to the bad network, we always use the thirdparty maven repo to run test. e.g., ``` build/sbt "test:testOnly *SQLQueryTestSuite" -Dspark.sql.maven.additionalRemoteRepositories=xxxxx ``` It's failed with such error msg ``` [info] - show-tblproperties.sql *** FAILED *** (128 milliseconds) [info] show-tblproperties.sql [info] Expected "...rredTempViewNames [][]", but got "...rredTempViewNames [][ [info] view.sqlConfig.spark.sql.maven.additionalRemoteRepositories xxxxx]" Result did not match for query #6 [info] SHOW TBLPROPERTIES view (SQLQueryTestSuite.scala:464) ``` It's not necessary to capture the maven config to view since it's a session level config.   ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? manual test pass ``` build/sbt "test:testOnly *SQLQueryTestSuite" -Dspark.sql.maven.additionalRemoteRepositories=xxx ``` Closes apache#31856 from ulysses-you/skip-maven-config. Authored-by: ulysses-you <ulyssesyou18@gmail.com> Signed-off-by: Kent Yao <yao@apache.org>
1 parent 010aeca commit 8fcb15d

File tree

1 file changed

+2
-1
lines changed
  • sql/core/src/main/scala/org/apache/spark/sql/execution/command

1 file changed

+2
-1
lines changed

sql/core/src/main/scala/org/apache/spark/sql/execution/command/views.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,8 @@ object ViewHelper {
348348
"spark.sql.codegen.",
349349
"spark.sql.execution.",
350350
"spark.sql.shuffle.",
351-
"spark.sql.adaptive.")
351+
"spark.sql.adaptive.",
352+
SQLConf.ADDITIONAL_REMOTE_REPOSITORIES.key)
352353

353354
private def shouldCaptureConfig(key: String): Boolean = {
354355
!configPrefixDenyList.exists(prefix => key.startsWith(prefix))

0 commit comments

Comments
 (0)