Android build hitting 4GB memory and OOM

Sometimes your Android builds need more than 4G of RAM and get OOM error. When you see the issue, you can try adding the following to your circle.yml.

machine:
  environment:
    GRADLE_OPTS: -Xmx1024m -XX:MaxPermSize=1024m
  java:
    version:
      oraclejdk8
6 Likes

Hi there,
I started getting the 4G limit error. I tried the solution described here and it didn’t work for me. Is there anything else I could do?

Thanks

2 Likes