Gradle jvmargs property from gradle.properties is not recognized in codemagic build #2427
Replies: 3 comments
-
hey @nateshmbhat, to resolve this Java heap error, let's try the solution that has helped different users as well. Let's allocate some memory for the heap space by modifying your
In this example, I have allocated 4096M(4GB) for the heap space, this should ensure that enough memory is allocated for the build process |
Beta Was this translation helpful? Give feedback.
-
I'm tentatively closing the discussion since we haven't heard back from you. You can open the discussion again by replying to this message or opening a new discussion. |
Beta Was this translation helpful? Give feedback.
-
@dtrdic i know this has been stale for quite sometime but i had a similar issue with my android flutter build. after abit of tinkering with the exec command you provided it seems to have done the trick.. however i still dont get why the specs i provided in my gradle.properties file didnt reflect needing to be provided from gradlew bash script. is there a reason the codemagic runner doesnt recognize the gradle.properties file ? |
Beta Was this translation helpful? Give feedback.
-
If you are looking for help, please confirm the following...
Which mobile framework are you using?
React Native
Steps to reproduce
Though i have specified the jvmargs in my gradle properties file ,
org.gradle.jvmargs=-Xmx4g -XX:MaxMetaspaceSize=2g
, i'm getting error during my android build thatcodemagic is not able to recognize the maxheap space and max meta space config that i have given in gradle.properties file.
So i tried running gradle with debug option and found below logs which say that env project properties and system project properties and empty 🤔
how do i resolve this issue ?
Expected results
Gradle should not say : 'The currently configured max heap space is '2 GiB' and the configured max metaspace is 'unknown''
This means it will use the value of jvmargs from the gradle.properties file in our project
Actual results
Gradle shows this warning before throwing error that it ran out of jvm heap space.
The currently configured max heap space is '2 GiB' and the configured max metaspace is 'unknown'
Build id (optional)
65fc5c0e5e7972cb09c330fd
Beta Was this translation helpful? Give feedback.
All reactions