-
Notifications
You must be signed in to change notification settings - Fork 28.5k
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
[SPARK-13294] [PROJECT INFRA] Remove MiMa's dependency on spark-class / Spark assembly #11178
Conversation
Test build #51162 has finished for PR 11178 at commit
|
LGTM provided tests pass. |
Test build #51168 has finished for PR 11178 at commit
|
Test build #51176 has finished for PR 11178 at commit
|
Test build #51214 has finished for PR 11178 at commit
|
Test build #51224 has finished for PR 11178 at commit
|
Test build #51228 has finished for PR 11178 at commit
|
This patch ended up changing substantially, so I'd like @ScrapCodes to take a quick look at it. In a nutshell:
|
Jenkins, retest this please. Any comments here? |
@JoshRosen I am sorry for the delay here, I will try to do it today itself. |
@@ -336,7 +336,6 @@ def build_spark_sbt(hadoop_version): | |||
# Enable all of the profiles for the build: | |||
build_profiles = get_hadoop_profiles(hadoop_version) + modules.root.build_profile_flags | |||
sbt_goals = ["package", | |||
"assembly/assembly", |
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.
A full assembly is no longer needed ?, how do you configure classpath ?
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.
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.
Understood, for tests assembly is no longer needed.
Looks good !, I have taken a quick look and did not actually ran it. Hoping the tests will ensure that. |
Jenkins, retest this please. |
Not sure what is causing this:
Prashant Sharma On Wed, Feb 17, 2016 at 2:07 PM, UCB AMPLab [email protected]
|
Jenkins, retest this please. |
@ScrapCodes, it's some transient Jenkins flakiness, not caused by this PR. |
Test build #51435 has finished for PR 11178 at commit
|
I guess that the PySpark test scripts also need to set |
Jenkins, retest this please. |
Test build #51449 has finished for PR 11178 at commit
|
@@ -133,14 +140,14 @@ object GenerateMIMAIgnore { | |||
val (privateClasses, privateMembers) = privateWithin("org.apache.spark") | |||
val previousContents = Try(File(".generated-mima-class-excludes").lines()). | |||
getOrElse(Iterator.empty).mkString("\n") | |||
File(".generated-mima-class-excludes") | |||
.writeAll(previousContents + privateClasses.mkString("\n")) | |||
File(".generated-mima-class-excludes").writeAll( |
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.
Here, I decided to sort things just to make debugging a little nicer for myself.
Actually, maybe I can roll back the changes to the exclude generation which were aimed at reducing log noise; those can go in separately and slitting them off will ease review. |
Reverted improvements, so the diff should be tiny. I'll now be able to confirm that the generated excludes match exactly. |
Test build #52887 has finished for PR 11178 at commit
|
Test build #52880 has finished for PR 11178 at commit
|
|
Modified the code to give more detail in the error message:
|
As it turns out I think we do need to pull in transitive deps of the old spark version given that we're no longer getting transitive deps from the new spark version (via |
Alright, MiMa passes, so I've gone ahead and merged with master to pull in the change to temporarily disable MiMa during the DF -> DS[Row] type aliasing / migration. Provided this passes compilation, I'm going to merge this to try to unblock other patches. |
Test build #52882 has finished for PR 11178 at commit
|
Test build #52896 has finished for PR 11178 at commit
|
Test build #52893 has finished for PR 11178 at commit
|
Test build #52891 has finished for PR 11178 at commit
|
I've rolled back a bunch of changes and minimized this patch to a point where I think it's safe and uncontroversial, so I'm going to merge this into master now so that it doesn't conflict. The changes here should come in handy when we work towards re-enabling the MiMa tests which were disabled in the DF-to-DS migration (/cc @marmbrus @liancheng). |
@JoshRosen MiMA check is re-enabled in PR #11656. |
For some reason, this PR breaks the following invocation:
The problem appears to be with this line SCALA_VERSION=$("$MVN" help:evaluate -Dexpression=scala.binary.version $@ 2>/dev/null\
| grep -v "INFO"\
| tail -n 1) which outputs this when run
Removing the Any ideas why this PR is interfering with the additional flags passed to Maven? |
Looking at the debug output by Maven, it looks like there were some project structure changes that interfere with Maven's ability to do parallel builds. See: nchammas/flintrock#93 (comment) Given that, I'm guessing there's nothing to do here since those project changes are probably not worth rejiggering just to get parallel builds working again. |
…/ Spark assembly This patch removes the need to build a full Spark assembly before running the `dev/mima` script. - I modified the `tools` project to remove a direct dependency on Spark, so `sbt/sbt tools/fullClasspath` will now return the classpath for the `GenerateMIMAIgnore` class itself plus its own dependencies. - This required me to delete two classes full of dead code that we don't use anymore - `GenerateMIMAIgnore` now uses [ClassUtil](http://software.clapper.org/classutil/) to find all of the Spark classes rather than our homemade JAR traversal code. The problem in our own code was that it didn't handle folders of classes properly, which is necessary in order to generate excludes with an assembly-free Spark build. - `./dev/mima` no longer runs through `spark-class`, eliminating the need to reason about classpath ordering between `SPARK_CLASSPATH` and the assembly. Author: Josh Rosen <[email protected]> Closes apache#11178 from JoshRosen/remove-assembly-in-run-tests.
This patch removes the need to build a full Spark assembly before running the
dev/mima
script.tools
project to remove a direct dependency on Spark, sosbt/sbt tools/fullClasspath
will now return the classpath for theGenerateMIMAIgnore
class itself plus its own dependencies.GenerateMIMAIgnore
now uses ClassUtil to find all of the Spark classes rather than our homemade JAR traversal code. The problem in our own code was that it didn't handle folders of classes properly, which is necessary in order to generate excludes with an assembly-free Spark build../dev/mima
no longer runs throughspark-class
, eliminating the need to reason about classpath ordering betweenSPARK_CLASSPATH
and the assembly.