I moderated this through, but I'll note that it should be sent to the us...@maven.apache.org list.
In answer to your question - the JDK libraries used by default buffer the entire stream into memory, so you must increase the JVM memory available to accommodate. Alternatively, you can use wagon-http or wagon-webdav as documented here: http://maven.apache.org/ant-tasks/examples/install-deploy.html (look for install-providers). More recent versions than 1.0-beta-2 are available. - Brett On 21/12/2011, at 3:41 AM, Lee Crawford wrote: > Maven Ant Task folks, > > Am having a problem with the artifact:deploy task and large artifacts. It > appears to attempt to copy the entirety of the artifact into the heap (via > ByteArrayOutputStream) as part of the process. This runs into trouble for > large artifacts. > > maven-global-snapshot: > [echo] Deploying to SNAPSHOT > [artifact:deploy] Deploying to > http://util.makingfun.com:8081/nexus/content/repositories/snapshots/ > [artifact:deploy] [INFO] Retrieving previous build number from > makingfun.snapshots > [artifact:deploy] Uploading: > bugsters/bugsters-client/1.0.0-SNAPSHOT/bugsters-client-1.0.0-20111220.162945-5.jar > to repository makingfun.snapshots at > http://util.makingfun.com:8081/nexus/content/repositories/snapshots/ > [artifact:deploy] Transferring 268018K from makingfun.snapshots > > BUILD FAILED > /Users/crawford/Workspace/bugsters/build.xml:47: The following error > occurred while executing this line: > /Users/crawford/Workspace/bugsters/build.xml:68: The following error > occurred while executing this line: > /Users/crawford/Workspace/bugsters/client/build/build.xml:191: > java.lang.OutOfMemoryError: Java heap space > at java.util.Arrays.copyOf(Arrays.java:2786) > at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94) > at sun.net.www.http.PosterOutputStream.write(PosterOutputStream.java:61) > at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:492) > at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:457) > at org.apache.maven.wagon.AbstractWagon.putTransfer(AbstractWagon.java:411) > at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:392) > at org.apache.maven.wagon.AbstractWagon.putTransfer(AbstractWagon.java:365) > at org.apache.maven.wagon.StreamWagon.put(StreamWagon.java:163) > at > org.apache.maven.artifact.manager.DefaultWagonManager.putRemoteFile(DefaultWagonManager.java:317) > at > org.apache.maven.artifact.manager.DefaultWagonManager.putArtifact(DefaultWagonManager.java:227) > at > org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:107) > at org.apache.maven.artifact.ant.DeployTask.doExecute(DeployTask.java:125) > at > org.apache.maven.artifact.ant.AbstractArtifactTask.execute(AbstractArtifactTask.java:751) > at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) > > > Of course, I can always run Ant with a larger memory size but it would be > nice if the task was updated to stream the content versus buffering it > fully in memory. > > Thanks much. Love the Maven integration with Ant. > > --lee -- Brett Porter br...@apache.org http://brettporter.wordpress.com/ http://au.linkedin.com/in/brettporter http://twitter.com/brettporter --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org For additional commands, e-mail: dev-h...@maven.apache.org