Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
3.1k views
in Java FTP by (280 points)
I actually tried to get files of size 30 mb repeatedly (10 files) within a span of 5 hrs. I found that all the files are transfered properly but my applications seems to run out of memory.
The file is a log file which keeps rotating rapidly, so i retrieve the same file in a routine.
The code actually looks like this.

FTPClient ftp = new FTPClient(hostName);
ftp.login(user, password);
ftp.setConnectMode(FTPConnectMode.PASV);
ftp.setType(FTPTransferType.ASCII);

try{
ftp.get(localFile,file);
} catch (Exception e) {
e.printStackTrace();
}
ftp.quit();

Do anyone have a similar problem If so how to find a remedy for it ?

regards,
vinothk

1 Answer

0 votes
by (162k points)
We have been pretty careful with memory management etc and the edtFTPj codebase has undergone years of testing and hundreds of eyes going through it, as well as thousands of deployments. While it is possible there is a memory leak there, it is more likely that the leak is elsewhere in your code.

I actually tried to get files of size 30 mb repeatedly (10 files) within a span of 5 hrs. I found that all the files are transfered properly but my applications seems to run out of memory.
The file is a log file which keeps rotating rapidly, so i retrieve the same file in a routine.

Categories

...