How to manage two (different) sockets without using threads?
Jordan
jordan.taylor2 at gmail.com
Wed Dec 13 12:39:09 EST 2006
Why are you trying to make this asynchronous? I think part of the point
of ftp using two sockets was to make it multithreaded. If you're going
to make it asynchronous, It's probably going to be easier to do the
"select"ing yourself, instead of relying on asyncore or asynchat.
Unless you have an insanely fast connection and/or really small files
on the server, using asynchronous socket handling is going to stop up
the server b/c select won't check the other sockets until the current
one is done with whatever it's doing.
billie wrote:
> Hi all.
> I'm (re)writing an FTP server application by using asyncore/asynchat
> modules.
> FTP tipically got two different channels: command and data.
> I'm succesfully managing command channel through asynchat framework,
> but I'm not sure about how to manage data channel without using a
> thread/subprocess.
> Is there an optimal to do that?
> Can anyone point me in the right direction?
More information about the Python-list
mailing list