On 29/10/2012 11:29pm, Guido van Rossum wrote:
I wonder if this could be done by varying the transports by platform? Not too many people are going to write new transports -- there just aren't that many options. And those that do might be doing something platform-specific anyway. It shouldn't be that hard to come up with a transport abstraction that lets protocol implementations work regardless of whether it's a UNIX style transport or a Windows style transport. UNIX systems with IOCP support could use those too.
Yes, having separate implementations of the transport layer should work. But I think it would be cleaner to put all the platform specific stuff in the pollster, and make the pollster poll-for-completion rather than poll-for-readiness. (Is this the "proactor pattern"?) That seems to be the direction libevent has moved in. -- Richard