asyncore: limiting number of simultaneous connections?

Steve Holden sholden at holdenweb.com
Thu Jul 25 10:56:28 EDT 2002


"Alex Martelli" <aleax at aleax.it> wrote in message
news:JcU%8.139488$vm5.4529193 at news2.tin.it...
> Steve Holden wrote:
>         ...
> > which a read condition is accepted. Any time the socket is so listed (in
> > the select.select() arguments) any number of simultaneous connections
> > might occur, though this is unlikely.
>
> Hmmm... ANY number?  Doesn't the N passed in socket.listen(N) provide
> an upper limit to the number of connection requests that may be at
> the same time outstanding?
>
OK, then "... any number of simultaneous connections allowed by the socket
..."

Technically, yes,  the N passed to socket.listen() specifies the number of
unanswered (queued) connection requests that the transport layer will allow
for the socket. We should also remember that usually the transport layer
itself will impose some upper limit on N.
-----------------------------------------------------------------------
Steve Holden                                 http://www.holdenweb.com/
Python Web Programming                http://pydish.holdenweb.com/pwp/
-----------------------------------------------------------------------









More information about the Python-list mailing list