Remove uncaughtException Handler in server.js #165

Open
felixge opened this Issue Dec 13, 2011 · 1 comment

Projects

None yet

2 participants

@felixge
felixge commented Dec 13, 2011

Please remove the uncaughtException handler in server.js:

https://github.com/Flotype/now/blob/master/lib/server.js#L4

Besides that a library should not try to become the global exception handler of my application, this is highly harmful as it may lead to applications going into a stale state because the stack was ripped in unexpected places.

The only sane way to deal with uncaught exceptions in node is to let the process die. (That's until we get Domains).

@ericz
ericz commented Dec 23, 2011

Hmm I understand that it is rather harmful to have the global uncaughtException handler, however there are currently insufficient validations to make sure no one user can bring down the entire server by providing very unexpected input. We'll continue to work on making sure input is validated so that a single user's actions don't trigger server crashes and then we can remove the uncaughtException handler. Resources for working on NowJS has been spread quite thin here which is why this has taken so long to be addressed, and for that I apologize.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment