-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-24590][BUILD] Make Jenkins tests passed with hadoop 3 profile #21588
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
4585d2d
fe8bc03
dd04f18
be6e288
c4c82ba
b9eeef3
a011e50
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -323,7 +323,7 @@ object SparkBuild extends PomBuild { | |
| // Note ordering of these settings matter. | ||
| /* Enable shared settings on all projects */ | ||
| (allProjects ++ optionallyEnabledProjects ++ assemblyProjects ++ copyJarsProjects ++ Seq(spark, tools)) | ||
| .foreach(enable(sharedSettings ++ DependencyOverrides.settings ++ | ||
| .foreach(enable(sharedSettings ++ DependencyOverrides.settings ++ ExcludeDependencies.settings ++ | ||
| ExcludedDependencies.settings ++ Checkstyle.settings)) | ||
|
|
||
| /* Enable tests settings for all projects except examples, assembly and tools */ | ||
|
|
@@ -471,7 +471,20 @@ object DockerIntegrationTests { | |
| object DependencyOverrides { | ||
| lazy val settings = Seq( | ||
| dependencyOverrides += "com.google.guava" % "guava" % "14.0.1", | ||
| dependencyOverrides += "jline" % "jline" % "2.14.6") | ||
| dependencyOverrides += "jline" % "jline" % "2.14.6", | ||
| dependencyOverrides += "com.fasterxml.jackson.core" % "jackson-annotations" % "2.6.7", | ||
| dependencyOverrides += "com.fasterxml.jackson.core" % "jackson-core" % "2.6.7", | ||
| dependencyOverrides += "com.fasterxml.jackson.core" % "jackson-module-jaxb-annotations" % "2.6.7", | ||
| dependencyOverrides += "com.fasterxml.jackson.core" % "jackson-databind" % "2.6.7") | ||
| } | ||
|
|
||
| /** | ||
| * Exclusions to work around sbt's dependency resolution being different from Maven's. | ||
| */ | ||
| object ExcludeDependencies { | ||
| lazy val settings = Seq( | ||
| excludeDependencies += "com.fasterxml.jackson.jaxrs" % "jackson-jaxrs-json-provider", | ||
| excludeDependencies += "javax.ws.rs" % "jsr311-api") | ||
|
||
| } | ||
|
|
||
| /** | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -177,7 +177,10 @@ private[hive] class IsolatedClientLoader( | |
|
|
||
| protected def isSharedClass(name: String): Boolean = { | ||
| val isHadoopClass = | ||
| name.startsWith("org.apache.hadoop.") && !name.startsWith("org.apache.hadoop.hive.") | ||
| name.startsWith("org.apache.hadoop.") && !name.startsWith("org.apache.hadoop.hive.") || | ||
| // Also, includes configuration2 as a min fix for Hadoop 3+ for now. This is failed | ||
| // during class resolution. It is fine when 'sharesHadoopClasses' is disabled. | ||
| name.startsWith("org.apache.commons.configuration2.") | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. To all, BTW, this fix is needed to land Hadoop 3 support into Apache spark.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @wangyum, if you face some errors like: later, consider this fix. It's been too old so I forgot the exact context about this but you might need this fix as well.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks @HyukjinKwon |
||
|
|
||
| name.startsWith("org.slf4j") || | ||
| name.startsWith("org.apache.log4j") || // log4j1.x | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,6 +18,7 @@ | |
| package org.apache.spark.sql.hive.client | ||
|
|
||
| import org.apache.hadoop.conf.Configuration | ||
| import org.apache.hadoop.util.VersionInfo | ||
| import org.scalactic.source.Position | ||
| import org.scalatest.Tag | ||
|
|
||
|
|
@@ -26,7 +27,6 @@ import org.apache.spark.sql.hive.HiveUtils | |
|
|
||
| private[client] abstract class HiveVersionSuite(version: String) extends SparkFunSuite { | ||
| override protected val enableAutoThreadAudit = false | ||
| protected var client: HiveClient = null | ||
|
||
|
|
||
| protected def buildClient( | ||
| hadoopConf: Configuration, | ||
|
|
@@ -49,6 +49,11 @@ private[client] abstract class HiveVersionSuite(version: String) extends SparkFu | |
|
|
||
| override protected def test(testName: String, testTags: Tag*)(testFun: => Any) | ||
| (implicit pos: Position): Unit = { | ||
| super.test(s"$version: $testName", testTags: _*)(testFun) | ||
| super.test(s"$version: $testName", testTags: _*) { | ||
| assume( | ||
| VersionInfo.getVersion < "3.0.0" || version >= "2.3", | ||
| "Hive 2.3+ supports Hadoop 3+. See HIVE-16081.") | ||
| testFun | ||
| } | ||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These look coming from
jackson-jaxrs-json-providerwhere it looks the resolution is different between Maven and SBT. I had to manually override and exclude.