On 29 Nov, 06:00, Bill Janssen <[EMAIL PROTECTED]> wrote: > I think it's simpler to let the SSL module do it, even though it comes > at the expense of blocking the thread till the handshake is complete.
> That's essentially what happens already. The question is whether the > SSL setup code is allowed to block the non-blocking socket till the > SSL handshake is complete. No, the SSL code should NOT be allowed to block anything in any case, even though the handshake is still not completed, in which case just retry it at a later time. Meanwhile the application must be able to do other things, like read or write from other sockets. If the handshake would complete in 1 second that would mean that the application won't do anything else until that operation is finished, holding up the entire loop. That means you would block other clients connected at that time (e.g. applications serving more than 1 client at time), transfers in progress and so on... That would be only reasonable when using threads or multiple processes but not in an asynchronous environment. _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com