Stopped batch service when draining
This commit is contained in:
parent
20fd536659
commit
1e49fbc33d
@ -19,6 +19,7 @@ Batch.prototype.start = function () {
|
||||
this._subscribe();
|
||||
|
||||
process.on('SIGTERM', function () {
|
||||
self.stop();
|
||||
self.drain(function (err) {
|
||||
if (err) {
|
||||
console.log('Exit with error');
|
||||
|
Loading…
Reference in New Issue
Block a user