Open samlecuyer opened 10 years ago
@samlecuyer Thanks for pointing out. Does this look ok - https://github.com/pranavparikh/arrow/blob/errorHandling/lib/util/arrowsetup.js ? Do you have any other recommendations ?
@pranavparikh cb is never invoked with any parameters. That's a problem
@samlecuyer Something like ?
ArrowSetup.prototype.startArrowServer = function(cb) {
var self = this;
try {
if (self.config.startArrowServer) {
Servermanager.startArrowServer(function(arrowServerStarted) {
if (arrowServerStarted === false) {
self.logger.error('Failed to start Arrow Server. Exiting !!!');
cb('Failed to start Arrow Server. Exiting !!!');
return;
}
cb();
});
}
}
catch(e) {
cb(e);
}
};
@pranavparikh much better
@samlecuyer Thanks.I'll work on this and we can go through the changes once I'm done.
https://github.com/yahoo/arrow/blob/master/lib/util/arrowsetup.js#L27
cb(null, ...)
ignores any error that happens.