Hello,

Thank you for the tips. By setting MAVEN_OPTS to -Xmx128m, the build works.

Clement

> -----Message d'origine-----
> De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] De la part de Stuart
> McCulloch
> Envoyé : dimanche 18 novembre 2007 14:07
> À : [email protected]
> Objet : Re: Error when building xml-api (in felix/commons) with the
> latest maven-bundle-plugin
> 
> FYI, Bnd v0.0.198 uses 16m whereas v0.0.199 uses 79m while bundling
> xml-api
> 
> On 18/11/2007, Stuart McCulloch <[EMAIL PROTECTED]> wrote:
> >
> > On 18/11/2007, Clement Escoffier <[EMAIL PROTECTED]> wrote:
> > >
> > > Hello,
> > >
> > >
> > >
> > > I am trying to build commons bundle with the latest maven-bundle-
> plugin
> > > (to
> > > get OBR support). It works fine except for xml-api where the error
> is
> > > really
> > > strange. It throws an OutOfMemory error (java heap space) when
> > > "bundlelizing" the project. The build works when using the
> > > maven-bundle-plugin 1.0.0. Somebody know how to solve this error ?
> >
> >
> > well I tried the latest bundle-plugin code with the old Bnd library (
> > 0.0.160)
> > and didn't get any OOM, so it looks like the new version is more
> memory
> > hungry... but it does do a lot more checking
> >
> > you could try increasing the heap available to Maven using MAVEN_OPTS
> > looks like "export MAVEN_OPTS=-Xmx128m" is enough, although I then
> > see a build error due to a missing import...
> >
> > Clement
> > >
> > >
> > >
> > > [WARNING] Include-Resource: overriding
> > >
> > > META-INF\LICENSE=src/main/resources/META-INF/LICENSE,META-
> INF\NOTICE=src/mai
> > > n/resources/META-INF/NOTICE with src/main/resources,
> > > @xercesImpl-2.8.1.jar!/META-INF/services/** ,
> > > @xalan-2.7.0.jar!/META-INF/services/** (add {maven-resources} if
> you
> > > want to
> > > include the maven resources)
> > >
> > > java.lang.OutOfMemoryError: Java heap space
> > >
> > >         at java.util.Arrays.copyOfRange(Arrays.java :3209)
> > >
> > >         at java.lang.String.<init>(String.java:216)
> > >
> > >         at
> java.io.DataInputStream.readUTF(DataInputStream.java:644)
> > >
> > >         at
> java.io.DataInputStream.readUTF(DataInputStream.java:547)
> > >
> > >         at aQute.lib.osgi.Clazz.constantUtf8(Clazz.java:308)
> > >
> > >         at aQute.lib.osgi.Clazz.parseClassFile(Clazz.java:92)
> > >
> > >         at aQute.lib.osgi.Clazz.<init>(Clazz.java:66)
> > >
> > >         at aQute.lib.osgi.Processor.analyzeJar(Processor.java:153)
> > >
> > >         at
> > > aQute.lib.osgi.Processor.analyzeBundleClasspath(Processor.java:71)
> > >
> > >         at aQute.lib.osgi.Verifier.verify(Verifier.java:354)
> > >
> > >         at aQute.lib.osgi.Builder.doVerify(Builder.java:207)
> > >
> > >         at aQute.lib.osgi.Builder.build(Builder.java:50)
> > >
> > >         at
> > >
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java
> > > :276)
> > >
> > >         at
> > >
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java
> > > :172)
> > >
> > >         at
> > >
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java
> > > :164)
> > >
> > >         at
> > >
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginM
> anage
> > > r.java:443)
> > >
> > >         at
> > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals
> > > (DefaultLife
> > > cycleExecutor.java:539)
> > >
> > >         at
> > >
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLife
> cycle
> > > (DefaultLifecycleExecutor.java:480)
> > >
> > >         at
> > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal
> > > (DefaultLifec
> > > ycleExecutor.java:459)
> > >
> > >         at
> > >
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandl
> eFail
> > > ures(DefaultLifecycleExecutor.java:311)
> > >
> > >         at
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments
> > > (Defa
> > > ultLifecycleExecutor.java:278)
> > >
> > >         at
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLife
> cycle
> > > Executor.java:143)
> > >
> > >         at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java
> > > :334)
> > >
> > >         at
> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
> > >
> > >         at org.apache.maven.cli.MavenCli.main (MavenCli.java:280)
> > >
> > >         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
> > >
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> > >
> > > java.lang.OutOfMemoryError : Java heap space
> > >
> > >         at aQute.lib.osgi.Clazz.parseClassFile(Clazz.java:84)
> > >
> > >         at aQute.lib.osgi.Clazz.<init>(Clazz.java:66)
> > >
> > >         at aQute.lib.osgi.Processor.analyzeJar(Processor.java :153)
> > >
> > >         at
> > > aQute.lib.osgi.Processor.analyzeBundleClasspath(Processor.java:71)
> > >
> > >         at aQute.lib.osgi.Verifier.verify(Verifier.java:354)
> > >
> > >         at aQute.lib.osgi.Builder.doVerify(Builder.java :207)
> > >
> > >         at aQute.lib.osgi.Builder.build(Builder.java:50)
> > >
> > >         at
> > >
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java
> > > :276)
> > >
> > >         at
> > > org.apache.felix.bundleplugin.BundlePlugin.execute
> (BundlePlugin.java
> > > :172)
> > >
> > >         at
> > >
> org.apache.felix.bundleplugin.BundlePlugin.execute(BundlePlugin.java
> > > :164)
> > >
> > >         at
> > > org.apache.maven.plugin.DefaultPluginManager.executeMojo
> > > (DefaultPluginManage
> > > r.java :443)
> > >
> > >         at
> > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals
> > > (DefaultLife
> > > cycleExecutor.java:539)
> > >
> > >         at
> > >
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLife
> cycle
> > > (DefaultLifecycleExecutor.java:480)
> > >
> > >         at
> > > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal
> > > (DefaultLifec
> > > ycleExecutor.java:459)
> > >
> > >         at
> > >
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandl
> eFail
> > > ures(DefaultLifecycleExecutor.java:311)
> > >
> > >         at
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments
> > > (Defa
> > > ultLifecycleExecutor.java:278)
> > >
> > >         at
> > >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLife
> cycle
> > > Executor.java:143)
> > >
> > >         at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java
> > > :334)
> > >
> > >         at
> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
> > >
> > >         at org.apache.maven.cli.MavenCli.main (MavenCli.java:280)
> > >
> > >         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
> > >
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> > >
> > >         at org.codehaus.classworlds.Launcher.main
> (Launcher.java:375)
> > >
> > > java.lang.OutOfMemoryError: Java heap space
> > >
> > >         at java.util.Arrays.copyOfRange(Arrays.java:3209)
> > >
> > >         at java.lang.String.<init>(String.java:216)
> > >
> > >         at java.io.DataInputStream.readUTF
> (DataInputStream.java:644)
> > >
> > >         at
> java.io.DataInputStream.readUTF(DataInputStream.java:547)
> > >
> > >         at aQute.lib.osgi.Clazz.constantUtf8(Clazz.java:308)
> > >
> > >         at aQute.lib.osgi.Clazz.parseClassFile (Clazz.java:92)
> > >
> > >         at aQute.lib.osgi.Clazz.<init>(Clazz.java:66)
> > >
> > > .
> > >
> > >
> > >
> > > --
> > >
> > > Clement Escoffier
> > >
> > > Grenoble University
> > >
> > > +33 (0) 4 76 51 40 24
> > >
> > > http://clement.plop-plop.net
> > >
> > >
> > >
> > >
> >
> >
> > --
> > Cheers, Stuart
> 
> 
> 
> 
> --
> Cheers, Stuart

Reply via email to