I have just released yet another Open-Source project. This was gracefully sponsored by PandaStream, so I thought I might as well post here. Let me introduce you to socketmaster.
In the tradition of UNIX, socketmaster does just one thing but does it well; it helps your app to restart without losing or refusing a single connection. socketmaster is the gatekeeper, keeping your sockets warm under the fire of restarts (christmas starts sooner every year isn’t it ? ho ho ho!).
To port your app to socketmaster you just need to do two things:
- Change the startup code to open the file-descriptor 3 as a socket listener.
- Gracefully shutdown on SIGHUP.