3

I attempted to change my heap size for maven easyb plugin http://www.easyb.org/maven-easyb-plugin/. In my easyb test I added standard code to print the heap size using the code Runtime.getFreeMemory() and Runtime.getTotalMemory().

I tried setting the MAVEN_OPTS=-Xmx1024m -Xms1024m and also set the maven opts in Maven surefire plugin. Now when I run the same class from the Junit I can see the getTotalMemory() displaying a number close 1Gig but the when the same classes are invoked from easyb plugin they do not reflect the memory size.

Shouldn't there be a way of passing JVM opts to maven easyb plugin when it runs these easyb tests? At the very minimum it should atleast pick up the MAVEN_OPTS settings from the environment.

Has someone bumped into problems like this? (A search on this group's archive does not reveal much)

trincot
  • 317,000
  • 35
  • 244
  • 286
vinnu
  • 31
  • 1

2 Answers2

0

Try to define

JAVA_OPTS=-Xmx1024m -Xms1024m

Probably, MAVEN_OPTS is even not necessary. My guess is that MAVEN forks a new JVM inside to run easyb. And, probably, it's wise of MAVEN to separate it's own JVM settings from settings for JVM it runs.

seas
  • 1,482
  • 2
  • 18
  • 29
0

This is Issue 77: Enhancement: specify max memory for maven plugin which is still "New" but has a patch (with tests) attached. So grab the sources, patch them and rebuild the plugin.

Pascal Thivent
  • 562,542
  • 136
  • 1,062
  • 1,124