Import of Maven project ends with
Exception java.lang.OutOfMemoryError: GC overhead limit exceeded
MAVEN_OPTS = -Xmx1g
.-Xmx1g
to Maven VM options via Settings -> Build Tools -> Maven -> Runner.Without success. What else can I do?
From the main menu, select Help | Change Memory Settings. Set the necessary amount of memory that you want to allocate and click Save and Restart.
It is possible to start Maven and sbt with increased memory. We recommend you increase the Maximum Metaspace size and the Thread Stack size. These values can be set using -Xss2M -XX:MaxMetaspaceSize=1024M . The exact values may depend on your hardware and your code base.
Limits the maximum memory heap size that the JVM can allocate for running IntelliJ IDEA. The default value depends on the platform. If you are experiencing slowdowns, you may want to increase this value, for example, to set the value to 2048 megabytes, change this option to -Xmx2048m .
The solution is to set -Xmx1g
(or more) in Maven VM options for importer (yes, it is a separate option!). Go to "Settings/Preferences -> Build Tools -> Maven -> Importing", and find the option there.
Read more on JVM heap size: (Q) What are the Xms
and Xmx
parameters when starting JVMs?.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With