Quantcast
Viewing all articles
Browse latest Browse all 174

[SOLVED] Gradle: How to increase the Java Compiler’s available Heap Memory

The documentation is not very clear on what all the available options are…
after much Googling and many different attempts finally figured out how to raise the maximum heap of the compiler from within the gradle script.

apply plugin: 'java'

compileJava {
    //raise heap
    options.fork = 'true'
    options.forkOptions.with {
        memoryMaximumSize = "2048m"
    }
}

Viewing all articles
Browse latest Browse all 174

Trending Articles