When I run my unit tests in Maven on windows, I get an OutOfMemory exception. I tried adding the -XX: -HeapDumpOnOutOfMemoryError parameter to the valid argLine argument, but no dump file is created. I also tried to add the same to MAVEN_OPTS, but still nothing, I just get an OutOfMemory exception and the process freezes until I manually crash it.
My pom looks like this:
<plugin> <artifactId>maven-surefire-plugin</artifactId> <configuration> <testFailureIgnore>false</testFailureIgnore> <argLine>-Xms512m -Xmx512m -XX:PermSize=256m -XX:-HeapDumpOnOutOfMemoryError</argLine> <forkMode>once</forkMode> </configuration> </plugin>
MAVEN_OPTS:
set MAVEN_OPTS=-XX:-HeapDumpOnOutOfMemoryError
Do you have an idea why a dump file is not created?
maven out-of-memory surefire
Koby
source share