It looks like it does fork since if I use jconsole, I will get a second JVM
that has identical properties as the first.  Part of the issue with this is
I notice that both JVMs will have the amount of memory I specify for
MAVEN_OPTS.  In the above case, 1GB.  If I run release:perform, the forked
JVM is maxed at 1 GB of memory when the error occurs.

I did try to run the JVM with 1284 MB for the maven instance (which is the
highest I can run it where the JVM will start), but in that case, my build
dies sooner because it can't allocate enough memory for the forked
instance.  The initial instance of Maven2 only uses 40K of memory, so it's
unnecessary for it to have as much memory as the spawned process.  The
server I'm building on, has 4GB of physical memory, but apparently enough
isn't available to have the initial Maven2 instance and the spawned one both
running at 1284MB of memory.

Other than checking out the tag, is the only other thing that the
release:perform does is a "deploy"?

Ryan

On Mon, Jun 8, 2009 at 10:35 AM, Baptiste MATHUS <[email protected]> wrote:

> Interesting. The artifact you're trying to deploy is 350MB+ large.
> Could you please try and just "mvn deploy" your project?
>
> I don't remember is the release plugin forks or not.
>
> My 2 cents,
> Cheers
>
> 2009/6/8 Ryan Moquin <[email protected]>
>
> > I'm trying to figure out why maven 2.1 is running out of heap space when
> I
> > do a release:perform on my project.  The project builds fine until I do a
> > release:perform in which case it runs out of memory.  The stack trace
> seems
> > to indicate that there was enough memory.  Do I need to give more memory
> to
> > the release plugin?  Here is the stacktrace, it seems like there is a
> > spawned JVM at the time of the error which doesn't have enough memory:
> >
> > [INFO] 262144/351338K
> > [INFO] 262148/351338K
> > [INFO] [INFO]
> > ------------------------------------------------------------------------
> > [INFO] [ERROR] FATAL ERROR
> > [INFO] [INFO]
> > ------------------------------------------------------------------------
> > [INFO] [INFO] Java heap space
> > [INFO] [INFO]
> > ------------------------------------------------------------------------
> > [INFO] [INFO] Trace
> > [INFO] java.lang.OutOfMemoryError: Java heap space
> > [INFO]  at java.util.Arrays.copyOf(Arrays.java:2786)
> > [INFO]  at
> > java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94)
> > [INFO]  at
> > sun.net.www.http.PosterOutputStream.write(PosterOutputStream.java:61)
> > [INFO]  at
> > org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:492)
> > [INFO]  at
> > org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:457)
> > [INFO]  at
> > org.apache.maven.wagon.AbstractWagon.putTransfer(AbstractWagon.java:411)
> > [INFO]  at
> > org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:392)
> > [INFO]  at
> > org.apache.maven.wagon.AbstractWagon.putTransfer(AbstractWagon.java:365)
> > [INFO]  at org.apache.maven.wagon.StreamWagon.put(StreamWagon.java:160)
> > [INFO]  at
> >
> >
> org.apache.maven.artifact.manager.DefaultWagonManager.putRemoteFile(DefaultWagonManager.java:262)
> > [INFO]  at
> >
> >
> org.apache.maven.artifact.manager.DefaultWagonManager.putArtifact(DefaultWagonManager.java:172)
> > [INFO]  at
> >
> >
> org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:107)
> > [INFO]  at
> > org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:190)
> > [INFO]  at
> >
> >
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:483)
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:678)
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:540)
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:519)
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:371
> > )
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:332)
> > [INFO]  at
> >
> >
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:181)
> > [INFO]  at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
> > [INFO]  at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
> > [INFO]  at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
> > [INFO]  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > [INFO]  at
> >
> >
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> > [INFO]  at
> >
> >
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> > [INFO]  at java.lang.reflect.Method.invoke(Method.java:597)
> > [INFO]  at
> > org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> > [INFO]  at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> > [INFO]  at
> > org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> > [INFO]  at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> > [INFO] [INFO]
> > ------------------------------------------------------------------------
> > [INFO] [INFO] Total time: 30 minutes 19 seconds
> > [INFO] [INFO] Finished at: Sat Jun 06 02:19:04 EDT 2009
> > [INFO] [INFO] Final Memory: 473M/1016M
> > [INFO] [INFO]
> > ------------------------------------------------------------------------
> > [INFO]
> > ------------------------------------------------------------------------
> > [ERROR] BUILD ERROR
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] Maven execution failed, exit code: '1'
> >
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] For more information, run Maven with the -e switch
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] Total time: 33 minutes 32 seconds
> > [INFO] Finished at: Sat Jun 06 02:19:21 EDT 2009
> > [INFO] Final Memory: 36M/65M
> > [INFO]
> > ------------------------------------------------------------------------
> >
> > Thanks,
> > Ryan
> >
>
>
>
> --
> Baptiste <Batmat> MATHUS - http://batmat.net
> Sauvez un arbre,
> Mangez un castor !
>

Reply via email to