JVM space exhausted when building a project through gradle

巧了我就是萌 提交于 2020-02-26 11:35:14

问题


Receiving error message when building a project through gradle

Expiring Daemon because JVM Tenured space is exhausted


回答1:


This means the JVM doesn't have enough memory to compile the Java files. There's a couple of steps that can be taken.

  1. Run ./gradlew clean, which will remove everything including leftovers from previous builds which are no longer relevant.
  2. Run ./gradlew --stop, killing other gradle daemons which may be taking up memory.
  3. Allocate more memory. This can be done by adding the following to the gradle.properties file.

org.gradle.jvmargs=-Xms128m -Xmx1024m -XX:+CMSClassUnloadingEnabled



来源:https://stackoverflow.com/questions/53854198/jvm-space-exhausted-when-building-a-project-through-gradle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!