In this scenario i read ftp directory, copy 2 files from ftp-server and then try to delete them...
I got these log
> CWD /
< 250 CWD command successful.
> CWD /
< 250 CWD command successful.
> CWD /
< 250 CWD command successful.
> CWD /
< 250 CWD command successful.
> TYPE A
< 200 Type set to A.
> PASV
< 227 Entering Passive Mode (10,1,0,213,15,121).
> LIST
Data connection established with 10.1.0.213:3961 on 03.12.2008 @ 11:44:44
< 125 Data connection already open; Transfer starting.
< 226 Transfer complete.
< 421 Timeout (120 seconds): closing control connection.
< 421 Terminating connection.
Disconnected from 10.1.0.213:21 on 03.12.2008 @ 11:47:12
Connected to 10.1.0.213:21 on 03.12.2008 @ 11:47:26
< 220 Microsoft FTP Service
> USER armentel_main\tech_slt_maf5_exp
< 331 Password required for armentel_main\tech_slt_maf5_exp.
> PASS *****
< 230 User armentel_main\tech_slt_maf5_exp logged in.
> CWD /
< 250 CWD command successful.
> TYPE I
< 200 Type set to I.
> PASV
< 227 Entering Passive Mode (10,1,0,213,15,181).
> RETR TICME20VMPM040551
Data connection established with 10.1.0.213:4021 on 03.12.2008 @ 11:47:26
< 125 Data connection already open; Transfer starting.
< 226 Transfer complete.
> CWD /
< 250 CWD command successful.
> DELE TICME20VMPM040551
< 250 DELE command successful.
> CWD /
< 250 CWD command successful.
> TYPE A
< 200 Type set to A.
> PASV
< 227 Entering Passive Mode (10,1,0,213,15,211).
> LIST
Data connection established with 10.1.0.213:4051 on 03.12.2008 @ 11:48:34
< 125 Data connection already open; Transfer starting.
< 226 Transfer complete.
> CWD /
< 250 CWD command successful.
> TYPE I
< 200 Type set to I.
> PASV
< 227 Entering Passive Mode (10,1,0,213,16,1).
> RETR TICME20VMPM040552
Data connection established with 10.1.0.213:4097 on 03.12.2008 @ 11:51:06
< 125 Data connection already open; Transfer starting.
< 226 Transfer complete.
> CWD /
< 250 CWD command successful.
> DELE TICME20VMPM040552
< 250 DELE command successful.
> CWD /
< 250 CWD command successful.
> TYPE A
call to 2nd file 'copy' method (RETR) takes a lot time (but it is size 500KB)
This is pared-down piece of code
AbstractFile[] files = provider.GetFiles(srcFolder, filters);
for (int i = 0; i < files.Length; i++)
{
//Log(Messages.FilesRest, files.Length - i);
AbstractFile file = files
;
file.copy();
FtpFile ftpfile = new FtpFile(connection, fullPath);
Logger.Log("DEBUG_COPY FtpFile created");
if (ftpfile.Exists) ftpfile .Delete();
}