Re: [twsocket] Multiple FTP Clients

2010-04-15 Thread GRAHAM (Deephaven)
When I investigated this single socket connection some years ago I just used
a standard Delphi client socket with the standard FTP commands. It is now
easier to use the multiple FTP clients to solve my problem. I am currently
at a convention and spoke to the server vendor and he agreed this idea was a
good solution.

The first attempt seems to have a problem (problem something stupid I'm
doing). I have 2 FTP clients and created 2 memory streams. If both FTP
clients connect and then disconnect, when I free the second memory stream I
get an error. If only one FTP client connects and disconnects, I can free
both memory streams.

Obviously doing something dim.

Graham


-Original Message-
From: twsocket-boun...@elists.org [mailto:twsocket-boun...@elists.org] On
Behalf Of Angus Robertson - Magenta Systems Ltd
Sent: 14 April 2010 07:32
To: twsocket@elists.org
Subject: Re: [twsocket] Multiple FTP Clients

 I am attempting to transfer and process a lot of files via a memory 
 stream. Conventional FTP seems to take about 200mS per transfer.
 Possibly due to the opening and closing of the data socket for each
 transfer.

This speed is as expected, the port for each data socket has to be
negotiated, then the TCP stream opened.  

The same speed issue occurs listing files in multiple directories, it can
take several minutes to parse a complex directory structure one at a time.


It's why the ICS FTP client and server have new FTP directory commands,
XCMLSD which lists directories using the control channel, and XDMLSD
which combines multiple directory listings into a single download.  

Do you have a specification for this UNIX server that sends data files on
the control connection, or a command log? 

Angus


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overb

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Multiple FTP Clients

2010-04-15 Thread Francois PIETTE

easier to use the multiple FTP clients to solve my problem.

The first attempt seems to have a problem (problem something stupid I'm
doing). I have 2 FTP clients and created 2 memory streams. If both FTP
clients connect and then disconnect, when I free the second memory stream 
I

get an error. If only one FTP client connects and disconnects, I can free
both memory streams.

Obviously doing something dim.


There is a bug in your code obviously. You are probably referencing the 
wrong stream.
btw: Usually one use TFileStream for FTP because you have potentially very 
large files which could result in out of memory errors if you use a 
TMemoryStream.


--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be