Hi,
I was wondering why you disabled the RESUME mode in uploadStream.
I see no particular reason for this not to work. If you change your FileTransferClient implementation from
public synchronized FileTransferOutputStream uploadStream(String remoteFileName, WriteMode writeMode)
throws FTPException, IOException {
checkTransferSettings();
if (WriteMode.RESUME.equals(writeMode))
throw new FTPException("Resume not supported for stream uploads");
boolean append = WriteMode.APPEND.equals(writeMode);
return new FTPOutputStream(ftpClient, remoteFileName, append);
}
to
public synchronized FileTransferOutputStream uploadStream(String remoteFileName, WriteMode writeMode)
throws FTPException, IOException {
checkTransferSettings();
boolean append = false;
if (writeMode.equals(WriteMode.RESUME)) {
ftpClient.resume();
}
else if (writeMode.equals(WriteMode.APPEND)) {
append = true;
}
return new FTPOutputStream(ftpClient, remoteFileName, append);
}
we should be almost set. The only missing thing is an getResumeMarker() on FTPOutputStream so that I can skip the input stream for x number of bytes before starting the copying.
Can this be added?
Thanks