Getting out of memory issue after updating buildToolsVersion '23.0.1' in Android studio

Getting out of memory issue after updating buildToolsVersion '23.0.1' in Android studio


I am getting out of memory issue very often after updating buildToolsVersion '22.0.1' to buildToolsVersion '23.0.1' I am really confused and dont know how to solve this issue, since this error showing only with buildTools version 23.0.1. Whereas it is working fine when I change it to 22.0.1. Please help me.

Solution:
1) I solved this problemgo to "System"
Environmental Setting Adwanced
Edit _JAVA_OPTIONS values from "-Xms1024m" to "-Xms2048m"
(if not Exist _JAVA_OPTIONS than create it click on New Button)
ok & save Restart

2)Actually for me worked a more complex solution, which combine all from above, plus enabling multidex in the build.gradle file for the module.

A. Add this line in the defaultConfig section to enable multiDex

// Enabling multidex support.
multiDexEnabled true
B. Than set the dexOptions, like this:

dexOptions {
incremental true
javaMaxHeapSize "4G"
}
Getting out of memory issue after updating buildToolsVersion '23.0.1' in Android studio Getting out of memory issue after updating buildToolsVersion '23.0.1' in Android studio Reviewed by Anonymous on September 14, 2016 Rating: 5

No comments:

Java Ternary Operator

Java Ternary Operator Java ternary operator is the only conditional operator that takes three operands. Java ternary operator is a one l...

Powered by Blogger.