allow_reuse_address! duh!
Doug Fort
dougfort at downright.com
Sun Jun 10 07:58:27 EDT 2001
My coworkers have been complaining about a particuraly annoying feature of
our agent infrastructure (http://pyagent.sourceforge.net): when you stop
an agent, you have to wait for something like two minutes to restart,
because the socket is busy.
While poking around for something else, I stumbled over the
allow_reuse_address class variable in SocketServer. Y'all may have known
about this for years, but it's news to me. All you have to do is set it
before initializing the TCPServer base class.
SocketServer.TCPServer.allow_reuse_address = 1
SocketServer.TCPServer.__init__(self, host, RequestHandler)
--
Doug Fort <dougfort at downright.com>
Senior Meat Manager
Downright Software LLC
http://www.downright.com
______________________________________________________________________
Posted Via Uncensored-News.Com - Still Only $9.95 - http://www.uncensored-news.com
With Seven Servers In California And Texas - The Worlds Uncensored News Source
More information about the Python-list
mailing list