In development, I'm seeing that when an exception is thrown on the server...I cannot access the app through the client until I restart Meteor in my terminal. This can take some time. Is this supposed to happen? On Prod, would this then require a manual Server restart? Thanks!
Is this supposed to happen?
Yes it is, however Meteor also restarts as soon as you edit one of your files, presumably to fix the cause of the exception.
On Prod, would this then require a manual Server restart?
yes, it would! Many people use forever to automatically restart their production app if that happens, but nowadays I really think one should use [Meteor-up] (http://meteor-up.com/) to deploy and run a production app. Moreover, I would highly recommend adding a catch-all in production. Someone in your server code add this:
process.on('uncaughtException', function(err) {
// handle the error safely
console.log("uncaughtException: ", err.message, err.stack);
});
By catching it this way, the exception will not cause the app to crash, i.e., an automatic restart is not necessary. Since there could still be other reasons to fail (e.g., out of memory issues), I would still recommend using meteor-up or similar in production. Presumably Meteor's Galaxy hosting will take care of that for you as well.