[FRPythoneers] Re: Asynch i/o in Python ?

Rahul Kumar rahulk at bhartitelesoft.com
Sun Sep 28 01:09:29 MDT 2003

Hi Sean
I am familiar with asyncore (which uses select(), which is synchronous,
but non-blocking). Even twisted uses the term "asynch" either to mean a
task is executed in another thread, or in the select() sense.

The issue with threads is that you land up having too many (one for each
connection), or limiting connections using a thread pool.

A select() uses the applications thread of control to query descriptor
sets, and only one thread can wait in the event loop on one descriptor

Unices provide an API called "aio" with calls such as asynch_read() and
asynch_write(). These allow us to use the Proactor pattern. I am hoping
someone's written a module to wrap around the same. Or maybe when i've
learned a little more of python, i'll attempt such a module!

> Date: Sat, 27 Sep 2003 11:16:36 -0600
> From: Sean Reifschneider <jafo at tummy.com>
> To: frpythoneers at lists.community.tummy.com
> Subject: Re: [FRPythoneers] Asynch i/o in Python ?
> Reply-To: frpythoneers at lists.community.tummy.com
> On Sat, Sep 27, 2003 at 11:39:28AM +0530, Rahul Kumar wrote:
> >Does python support asynch i/o (as in the aio package on Unix:
> >asynch_read, asynch_write, etc) ? I don't mean just non-blocking i/o as
> >in select().
> You will want to look at the "asyncore" standard-library module and
> Twisted Python at twistedmatrix.com.
> Sean
> -- 
>  <+kritical> christin: you need to learn how to figure out stuff yourself..
>  <+Christin1> how do i do that
> Sean Reifschneider, Member of Technical Staff <jafo at tummy.com>
> tummy.com, ltd. - Linux Consulting since 1995.  Qmail, Python, SysAdmin

More information about the FRPythoneers mailing list