> On Nov. 20, 2014, 11:09 p.m., Joshua Cohen wrote:
> > Why do we have to do this in buildSrc/build.gradle and not the root 
> > build.gradle?
> 
> Zameer Manji wrote:
>     buildSrc is special and run before the build.gradle: 
> http://www.gradle.org/docs/current/userguide/organizing_build_logic.html#sec:build_sources

To expand, my concern is that now when we bump gradle versions we'll have to 
update it in two places (we define the version for the wrapper task in the root 
build.gradle, it'd be nicer if we could have a single GRADLE_VERSION constant 
used by both).


- Joshua


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/28302/#review62453
-----------------------------------------------------------


On Nov. 20, 2014, 11:05 p.m., Zameer Manji wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/28302/
> -----------------------------------------------------------
> 
> (Updated Nov. 20, 2014, 11:05 p.m.)
> 
> 
> Review request for Aurora, Joshua Cohen, Kevin Sweeney, and Bill Farner.
> 
> 
> Bugs: AURORA-941
>     https://issues.apache.org/jira/browse/AURORA-941
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> The source tarball does not have gradlew and therefore is there is no way to 
> ensure the code will be built with the correct version of Gradle. This patch 
> fails the build if we are not building with the correct version of Gradle. 
> This provdes a much nicer error message to the user.
> 
> 
> Diffs
> -----
> 
>   buildSrc/build.gradle PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/28302/diff/
> 
> 
> Testing
> -------
> 
> Incorrect version:
> ````
> $ ~/Downloads/gradle-2.1/bin/gradle clean test
> 
> FAILURE: Build failed with an exception.
> 
> * Where:
> Build file '/Users/zmanji/workspace/aurora/buildSrc/build.gradle' line: 2
> 
> * What went wrong:
> A problem occurred evaluating root project 'buildSrc'.
> > Building is only supported with gradle version 2.2.
> 
> * Try:
> Run with --stacktrace option to get the stack trace. Run with --info or 
> --debug option to get more log output.
> 
> BUILD FAILED
> 
> Total time: 0.952 secs
> ````
> 
> Correct version:
> ````
> $ ./gradlew clean test
> :buildSrc:clean
> :buildSrc:compileJava UP-TO-DATE
> :buildSrc:compileGroovy
> :buildSrc:processResources UP-TO-DATE
> :buildSrc:classes
> :buildSrc:jar
> :buildSrc:assemble
> :buildSrc:compileTestJava UP-TO-DATE
> :buildSrc:compileTestGroovy UP-TO-DATE
> :buildSrc:processTestResources UP-TO-DATE
> :buildSrc:testClasses UP-TO-DATE
> :buildSrc:test UP-TO-DATE
> :buildSrc:check UP-TO-DATE
> :buildSrc:build
> :clean
> :bootstrapThrift UP-TO-DATE
> :checkPython
> :generateSources
> :compileGeneratedJava
> Note: Some input files use unchecked or unsafe operations.
> Note: Recompile with -Xlint:unchecked for details.
> :processGeneratedResources UP-TO-DATE
> :generatedClasses
> :compileJava
> Note: Writing 
> file:/Users/zmanji/workspace/aurora/dist/classes/main/com/twitter/common/args/apt/cmdline.arg.info.txt.2
> :processResources
> :classes
> :compileTestJava
> :processTestResources
> :testClasses
> :test
> objc[67076]: Class JavaLaunchHelper is implemented in both 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/bin/java and 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/jre/lib/libinstrument.dylib.
>  One of the two will be used. Which one is undefined.
> objc[67077]: Class JavaLaunchHelper is implemented in both 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/bin/java and 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/jre/lib/libinstrument.dylib.
>  One of the two will be used. Which one is undefined.
> objc[67078]: Class JavaLaunchHelper is implemented in both 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/bin/java and 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/jre/lib/libinstrument.dylib.
>  One of the two will be used. Which one is undefined.
> objc[67079]: Class JavaLaunchHelper is implemented in both 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/bin/java and 
> /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/jre/lib/libinstrument.dylib.
>  One of the two will be used. Which one is undefined.
> :jacocoTestReport
> Coverage report generated: 
> file:///Users/zmanji/workspace/aurora/dist/reports/jacoco/test/html/index.html
> :analyzeReport
> Instruction coverage of 0.89 exceeds min instruction coverage of 0.88 by more 
> than 0.005, please raise the threshold!
> Branch coverage of 0.84 exceeds min instruction coverage of 0.83 by more than 
> 0.005, please raise the threshold!
> 
> BUILD SUCCESSFUL
> 
> Total time: 1 mins 28.786 secs
> ````
> 
> 
> Thanks,
> 
> Zameer Manji
> 
>

Reply via email to