On 17/12/2015 13:03, Glyph Lefkowitz
It's a MUD server, so players type in commands and receive
One of the admin commands is the ability to shutdown the
server (or CTRL-C might be pressed on the console). I'd
like this action to notify all connected transports that
the server is going down for shutdown, so they're not
rudely disconnected, then once the notifications have all
gone through, then the server is free to shutdown.
Gotcha. So you don't need to necessarily wait for all the
messages to be delivered if there are slow clients waiting
around; you just want to send everyone a farewell message and
if they haven't responded within a reasonable timeout, go
ahead and shut down anyway.
Will that work for you?
I hope all
this makes sense.
It's not a service no... Should it be? I wasn't planning to use
twistd, mainly because I don't know how to, and running
is working fine, accepting command line arguments - the works.
It could be converted though, if there is an advantage with
Also, I've read quite a lot about Deferreds. I thought initially
they were for multithreading your application, but I realise that's
wrong, so I don't understand what the point in them is?
This isn't to say there isn't one mind you, I think I'm just majorly
missing the point.
Sorry, I'll do that in the future.
Twisted-Python mailing list