title: Clover Java heap space error
body: <p>I am getting java heap space error while running from hudson and I set my <code>MAVEN_OPTS</code> as below, any body can let me know what is the resolution for this issue.</p>
  
  <pre><code>-Xmx4096m -XX:PermSize=3000m -XX:MaxPermSize=4096m
  </code></pre>
  
  <pre> 
      [INFO] ------------------------------------------------------------------------
      [ERROR] FATAL ERROR
      [INFO] ------------------------------------------------------------------------
      [INFO] Java heap space
      [INFO] ------------------------------------------------------------------------
      [INFO] Trace`enter code here`
      java.lang.OutOfMemoryError: Java heap space
          at java.util.BitSet.initWords(BitSet.java:144)
          at java.util.BitSet.(BitSet.java:139)
          at com.cenqua.clover.InMemPerTestCoverage.(InMemPerTestCoverage.java:66)
          at com.cenqua.clover.CloverDatabase.mergePerTestCoverage(CloverDatabase.java:494)
          at com.cenqua.clover.CloverDatabase.merge(CloverDatabase.java:437)
          at com.cenqua.clover.CloverMerge.mainImpl(CloverMerge.java:36)
          at com.atlassian.maven.plugin.clover.CloverAggregateMojo.mergeCloverDatabases(CloverAggregateMojo.java:260)
          at com.atlassian.maven.plugin.clover.CloverAggregateMojo.execute(CloverAggregateMojo.java:79)
          at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
          at hudson.maven.agent.PluginManagerInterceptor.executeMojo(PluginManagerInterceptor.java:182)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
          at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
          at org.apache.maven.lifecycle.LifecycleExecutorInterceptor.execute(LifecycleExecutorInterceptor.java:65)
          at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
          at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
          at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
          at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
          at hudson.maven.agent.Main.launch(Main.java:185)
          at hudson.maven.MavenBuilder.call(MavenBuilder.java:165)
          at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:1005)
          at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:936)
          at hudson.remoting.UserRequest.perform(UserRequest.java:118)
          at hudson.remoting.UserRequest.perform(UserRequest.java:48)
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 87 minutes 35 seconds
      [INFO] Finished at: Thu Jul 21 12:20:13 PDT 2011
      [INFO] Final Memory: 112M/3123M
      [INFO] ------------------------------------------------------------------------
      channel stopped
      Publishing Clover coverage report...
  </pre>