Hi friends
How to increase the Java heap memory for Maven 3 on windows7?I'm getting this error while building maven project:"java.lang.OutOfMemoryError: PermGen space”
thanks
emma smith wrote:How to increase the Java heap memory for Maven 3 on windows7?I'm getting this error while building maven project:"java.lang.OutOfMemoryError: PermGen space”
For Maven? Dunno. It's a parameter to the java command normally.
However, before you start increasing heap space, you might want to ask yourself why. The defaults are usually more than adequate for a normal program, so if you're exceeding it, it might indicate a problem with your code.
Winston Gutkowski wrote:For Maven? Dunno. It's a parameter to the java command normally.
However, before you start increasing heap space, you might want to ask yourself why. The defaults are usually more than adequate for a normal program, so if you're exceeding it, it might indicate a problem with your code.
Winston
yes, for maven i'm sure that the code is correct because i want to run apache stanbol launcher, it isn't my code!
Winston Gutkowski wrote:However, before you start increasing heap space, you might want to ask yourself why. The defaults are usually more than adequate for a normal program, so if you're exceeding it, it might indicate a problem with your code.
Maven is well-known for needing oodles of memory, especially for large projects. It's a build-time tool, so what the code actually does makes little difference - there are probably lots of classes, or other build-time complications.
Maven JVM options can be set via the MAVEN_OPTS environment variable. On a Unix-ish system it would be something like "setenv MAVEN_OPTS -Xmx1024m -XX:MaxPermSize=128m".
Ulf Dittmer wrote:Maven is well-known for needing oodles of memory, especially for large projects. It's a build-time tool, so what the code actually does makes little difference - there are probably lots of classes, or other build-time complications.
Oops. My apologies then Emma: listen to Ulf; he knoweth of which he speak.
Ulf Dittmer wrote:
Maven JVM options can be set via the MAVEN_OPTS environment variable. On a Unix-ish system it would be something like "setenv MAVEN_OPTS -Xmx1024m -XX:MaxPermSize=128m".
Ok Ulf, i have done it but yet i'm getting java.long.outOfMemeryError!
do you have any more suggestion? don't you think i change the version of maven?
emma smith wrote:
yes, for maven i'm sure that the code is correct because i want to run apache stanbol launcher, it isn't my code!
Why it wastes that much RAM, do you run Apache Stanbol launcher within Maven hosted JVM? In this case you better to fork another process with JVM for Stanbol.
surlac surlacovich wrote:
Why it wastes that much RAM, do you run Apache Stanbol launcher within Maven hosted JVM? In this case you better to fork another process with JVM for Stanbol.
can you explain more Surlac? exactly what should i do?