You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Mark Derricutt <ma...@talios.com> on 2009/04/18 10:16:40 UTC
OutOfMemoryError in maven-bundle-plugin when using multi-module
builds
'lo all,
Is there anyway to increase the heap memory setting in the
maven-bundle-plugin at all? On one of my machines when I try to build
our project as part of a large (15 or so modules) reactor build I get
OutOfMemory (when building standalone its fine).
The exception is:
java.lang.OutOfMemoryError: Java heap space
at java.util.Arrays.copyOf(Arrays.java:2786)
at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94)
at aQute.lib.osgi.EmbeddedResource.copy(EmbeddedResource.java:64)
at aQute.lib.osgi.EmbeddedResource.collect(EmbeddedResource.java:53)
at aQute.lib.osgi.EmbeddedResource.build(EmbeddedResource.java:35)
at aQute.lib.osgi.EmbeddedResource.build(EmbeddedResource.java:73)
at aQute.lib.osgi.Analyzer.analyzeBundleClasspath(Analyzer.java:1582)
at aQute.lib.osgi.Analyzer.analyze(Analyzer.java:108)
at aQute.lib.osgi.Builder.analyze(Builder.java:294)
at aQute.lib.osgi.Builder.doConditional(Builder.java:260)
at aQute.lib.osgi.Builder.build(Builder.java:75)
at org.apache.felix.bundleplugin.BundlePlugin.buildOSGiBundle(BundlePlugin.java:391)
at org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:282)
at org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:236)
at org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:227)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:678)
I've tried running 'MAVEN_OPS="-Xmx1024m" clean install' to no avail,
any one have any ideas or suggestions?
Currently I'm now just doing a "find . -name pom.xml --execdir mvn
clean install ';'" to work around it.
Mark
--
...and then Buffy staked Edward. The End.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org
Re: OutOfMemoryError in maven-bundle-plugin when using multi-module
builds
Posted by Mark Derricutt <ma...@talios.com>.
Doh. I think I shall go hide in the corner now :( Yes, I was missing
the T - and now everything works :)
PS: It was version 2.0.0 of the plugin.
On Sat, Apr 18, 2009 at 11:29 PM, Stuart McCulloch <mc...@gmail.com> wrote:
> ^ shouldn't that be MAVEN_OPTS?
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org
Re: OutOfMemoryError in maven-bundle-plugin when using multi-module
builds
Posted by Stuart McCulloch <mc...@gmail.com>.
2009/4/18 Mark Derricutt <ma...@talios.com>
> 'lo all,
>
> Is there anyway to increase the heap memory setting in the
> maven-bundle-plugin at all?
the maven-bundle-plugin just uses the normal Java heap, it doesn't specify
any additional limits
btw, which version of the plugin are you using? before 1.4.3 there was a
leak to do with closing jars
On one of my machines when I try to build
> our project as part of a large (15 or so modules) reactor build I get
> OutOfMemory (when building standalone its fine).
>
> The exception is:
>
> java.lang.OutOfMemoryError: Java heap space
> at java.util.Arrays.copyOf(Arrays.java:2786)
> at
> java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94)
> at aQute.lib.osgi.EmbeddedResource.copy(EmbeddedResource.java:64)
> at aQute.lib.osgi.EmbeddedResource.collect(EmbeddedResource.java:53)
> at aQute.lib.osgi.EmbeddedResource.build(EmbeddedResource.java:35)
> at aQute.lib.osgi.EmbeddedResource.build(EmbeddedResource.java:73)
> at
> aQute.lib.osgi.Analyzer.analyzeBundleClasspath(Analyzer.java:1582)
> at aQute.lib.osgi.Analyzer.analyze(Analyzer.java:108)
> at aQute.lib.osgi.Builder.analyze(Builder.java:294)
> at aQute.lib.osgi.Builder.doConditional(Builder.java:260)
> at aQute.lib.osgi.Builder.build(Builder.java:75)
> at
> org.apache.felix.bundleplugin.BundlePlugin.buildOSGiBundle(BundlePlugin.java:391)
> at
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:282)
> at
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:236)
> at
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java:227)
> at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:483)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:678)
>
> I've tried running 'MAVEN_OPS="-Xmx1024m" clean install' to no avail,
> any one have any ideas or suggestions?
>
^ shouldn't that be MAVEN_OPTS?
some people resort to editing the mvn scripts directly to make sure the
setting gets onto the command line...
> Currently I'm now just doing a "find . -name pom.xml --execdir mvn
> clean install ';'" to work around it.
>
> Mark
>
> --
> ...and then Buffy staked Edward. The End.
>
--
Cheers, Stuart