When close() is just not enough
JavaScript
Switch branches/tags
Nothing to show
Latest commit 13f04e4 May 20, 2015 @isaacs isaacs v1.0.1
Permalink
Failed to load latest commit information.
LICENSE isc license May 20, 2015
README.md readme Apr 4, 2013
index.js code Apr 4, 2013
package.json v1.0.1 May 20, 2015
test.js test Apr 4, 2013

README.md

server-destroy

Enable destroying a server, and all currently open connections.

Usage

var enableDestroy = require('server-destroy');

var server = http.createServer(function(req, res) {
  // do stuff, blah blah blah
});

server.listen(PORT);

// enhance with a 'destroy' function
enableDestroy(server);

// some time later...
server.destroy();