Gradle is slow


(will.not.read.this) #1

I have a multiproject maven build that runs it’s test within about 40 seconds (all code already compiled):

[INFO] ------------------------------------------------------------------------
[INFO] Building ParAd-distribution 5.1.0-RC01
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] ParAd-All ......................................... SUCCESS [0.003s]
[INFO] ParaProcessExecutor ............................... SUCCESS [6.144s]
[INFO] ParadVirtualDownload .............................. SUCCESS [0.387s]
[INFO] ParAd ............................................. SUCCESS [17.898s]
[INFO] CustomerParameterDef .............................. SUCCESS [4.543s]
[INFO] ParadFileMerger ................................... SUCCESS [0.533s]
[INFO] AsapFileGenerator ................................. SUCCESS [9.104s]
[INFO] ParadVariantBuilder ............................... SUCCESS [1.883s]
[INFO] ParAd-distribution ................................ SUCCESS [0.009s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 40.859s
[INFO] Finished at: Tue Sep 18 14:11:35 CEST 2012
[INFO] Final Memory: 16M/99M
[INFO] ------------------------------------------------------------------------

I converted the build using the maven2Greadle plugin and ran the thest on the verry same precompiled code it takes much more time:

D:\PARAD-Application>gradle test
 ...
complete outut here: http://pastie.org/4747000
  BUILD SUCCESSFUL
  Total time: 16 mins 41.372 secs
D:\PARAD-Application>

how can I speed up Greadle to be at lease nearly as fast a maven?

bye Thomas


(will.not.read.this) #2

The second run saves me 37 seconds:

complete output here: http://pastie.org/4747063
  BUILD SUCCESSFUL
  Total time: 16 mins 4.084 secs
D:\MKS-Sandboxes-mount-as-E\PACS\dev\PARAD-Application>

bye Thomas


(Luke Daley) #3

You can run with ‘–profile’ to see where the time is being spent.


(will.not.read.this) #4

I ran Gradle with the –profile option but the output did not change. :o(

But by looking at the process I’d say that greadle has problems to access the mavencentral repository.

bye Thomas


(Peter Niederwieser) #5

‘–profile’ doesn’t log to the console; it creates an HTML report under ‘build/reports/profile’. If it’s a communication problem with a repository, turning on info or debug logging may provide additional information.


(will.not.read.this) #6

The report confirmed, that resolving depenencies consumed all the time.

I configured proxy settings in

gradle.properties
and now the build runs in 30 seconds.

:o)

BTW: how do I mark this beeing solved?

bye Thomas


(will.not.read.this) #7

how do I get the typewriter text font? bye Thomas


(Luke Daley) #8

You can use markdown syntax in here. Surrounding a phrase in backticks gives you a monospace font.


(Luke Daley) #9

We (the admins) mark things as solved when the poster comes back saying they’ve resolved their issue.