Test of socket recovery code.
Add app.js
fix missing 'fs' require
add an error handler to fs.unlink
additional error handling
fix
add shutdown handler
final cleanup before merge