Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 57522 invoked from network); 8 Mar 2007 12:56:47 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 Mar 2007 12:56:47 -0000 Received: (qmail 74781 invoked by uid 500); 8 Mar 2007 12:56:54 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 74710 invoked by uid 500); 8 Mar 2007 12:56:53 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 74699 invoked by uid 99); 8 Mar 2007 12:56:53 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Mar 2007 04:56:53 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Mar 2007 04:56:44 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 4672E71406F for ; Thu, 8 Mar 2007 04:56:24 -0800 (PST) Message-ID: <9766121.1173358584285.JavaMail.root@brutus> Date: Thu, 8 Mar 2007 04:56:24 -0800 (PST) From: "Marty Lamb (JIRA)" To: commons-dev@jakarta.apache.org Subject: [jira] Commented: (VFS-107) large Sftp transfers fail with OutOfMemoryError: Java heap space In-Reply-To: <25428760.1168882227587.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/VFS-107?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12479298 ] Marty Lamb commented on VFS-107: -------------------------------- Sorry, should have commented on this much sooner. That seems to work for me - thanks! > large Sftp transfers fail with OutOfMemoryError: Java heap space > ---------------------------------------------------------------- > > Key: VFS-107 > URL: https://issues.apache.org/jira/browse/VFS-107 > Project: Commons VFS > Issue Type: Bug > Affects Versions: Nightly Builds > Environment: java version "1.5.0_04" > Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_04-b05) > Java HotSpot(TM) Client VM (build 1.5.0_04-b05, mixed mode, sharing) > Linux version 2.6.17-1.2142_FC4 (bhcompile@hs20-bc1-4.build.redhat.com) (gcc version 4.0.2 20051125 (Red Hat 4.0.2-8)) #1 Tue Jul 11 22:41:14 EDT 2006 > Reporter: Marty Lamb > Attachments: SftpFileObject.java > > > Calling SftpFileObject.getOutputStream() returns a descendant of ByteArrayOutputStream; nothing is written to the remote sftp server until the OutputStream is closed. For large data transfers, this exhausts local resources. > This is noted in the source for SftpFileObject: > protected OutputStream doGetOutputStream(boolean bAppend) throws Exception > { > // TODO - Don't write the entire file into memory. Use the stream-based > // methods on ChannelSftp once the work properly > final ChannelSftp channel = fileSystem.getChannel(); > return new SftpOutputStream(channel); > } > although it is not clear what "once the[y] work properly" is referring to. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org