commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Ferguson" <Andrew.Fergu...@arm.com>
Subject RE: Flush by net.ftp.FTPClient.retrieveFile(String, OutputStream)
Date Mon, 06 Sep 2004 15:18:44 GMT
quick suggestion - is it possible to use FTPClient.retrieveStream instead? if I understand,
you'd have to write the glue code but I'd guess there was a reason for calling flush so often
(?)


-----Original Message-----
From: Marco Jacob [mailto:mjacob@picturesafe.de] 
Sent: 06 September 2004 15:57
To: commons-user@jakarta.apache.org
Subject: Flush by net.ftp.FTPClient.retrieveFile(String, OutputStream)

I am new to this list.
Today I switched to the new commons-net.jar libraries because I found out that

   FTPClient.retrieveFile(String, OutputStream)

flushes the OutputStream after each time it calls write(byte[], int, int).
Unfortunately I habe an RMIOutputStream that transfers the data to a client.
The flush call makes RMIOutputStream write every 1024 over RMI while the buffer to transfer
is 1MB.

I think, FTPClient.retrieveFile(String, OutputStream) should never flush or close() the given
OutputStream. The calling method should do this.

However, can this be changed in the next release?
--
Marco Jacob
picturesafe GmbH
Software Development
Lüerstraße 3
D-30175 Hannover
GERMANY

Fon: +49 511 - 856 20 54
Fax: +49 511 - 856 20 10
mailto:mjacob@picturesafe.de



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message