Support Android builds larger than 500MB in size
When we try to make build for android of app size more than 500mb it will give us java.lang.OutOfMemoryError error. Please increase the java memory allowance limit for future releases.
Platforms involved Building on: All Android devices.
Full build log
WARNING: [XmlResourcesTransformer] No mapping for: android/support/FILE_PROVIDER_PATHS Exception in thread "ForkJoinPool.commonPool-worker-9" java.lang.OutOfMemoryError: Java heap space Failed to execute org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker@43b0d0d3. java.lang.OutOfMemoryError: Java heap space Exception in thread "ForkJoinPool.commonPool-worker-5" java.lang.OutOfMemoryError: Java heap space Exception in thread "Execution worker Thread 3" java.lang.OutOfMemoryError: Java heap space Exception in thread "Execution worker Thread 6" java.lang.OutOfMemoryError: Java heap space Exception in thread "Execution worker Thread 7" java.lang.OutOfMemoryError: Java heap space Exception in thread "Execution worker" java.lang.OutOfMemoryError: Java heap space
FAILURE: Build failed with an exception.
-
What went wrong: Java heap space
-
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
- Get more help at https://help.gradle.org
There are many games bigger than 500 mb in size such as Veritas. Can this be related to largeHeap option? Also, found this on the forums.
I think issue is with Java running out of memory when building the app. Not during the runtime.
@Shchvova Yes you are right. Looking forward for this fix in next release.
It's fixed in 3709.