Message185483
I managed to write a container class which listens on multiples addresses and uses select/poll on accept() as suggested by Charles.
FWICT it seems to work pretty well and supports non-blocking sockets and timeouts (tested on Linux, Windows and OSX).
It is available as a recipe here:
http://code.activestate.com/recipes/578504
IMO has_dual_stack() and create_server_sock() functions can already be included as-is (will adapt the recipe in order to get rid of Python 2.X support and submit another patch).
As for including also MultipleSocketsListener that's debatable.
It can either be added or linked/mentioned it in the doc. |
|
Date |
User |
Action |
Args |
2013-03-29 02:14:25 | giampaolo.rodola | set | recipients:
+ giampaolo.rodola, gvanrossum, pitrou, neologix |
2013-03-29 02:14:25 | giampaolo.rodola | set | messageid: <1364523265.63.0.60944596504.issue17561@psf.upfronthosting.co.za> |
2013-03-29 02:14:25 | giampaolo.rodola | link | issue17561 messages |
2013-03-29 02:14:25 | giampaolo.rodola | create | |
|