This commit is contained in:
Luis Fernando Molina committed 2020-11-27 20:23:49 +01:00
1 parent cf5e137c0f
commit 5732f0dd3a
2 files changed
+3 -3

No files matched your search

@@ -4,6 +4,7 @@ exports.newSuperalgosFunctionLibrariesNodeJSFunctions = function () {
exitProcess: exitProcess
}
let isNodeJsProcessShuttingDown = false
return thisObject
function exitProcess() {
@@ -12,8 +13,8 @@ exports.newSuperalgosFunctionLibrariesNodeJSFunctions = function () {
TS.projects.superalgos.functionLibraries.taskFunctions.taskError(undefined, "An unexpected error caused the Task to stop.")
}
if (global.SHUTTING_DOWN_PROCESS === true) { return }
global.SHUTTING_DOWN_PROCESS = true
if (isNodeJsProcessShuttingDown=== true) { return }
isNodeJsProcessShuttingDown = true
/* Signal that all sessions are stopping. */
TS.projects.superalgos.functionLibraries.sessionFunctions.finalizeSessions()
-1
View File
@@ -26,7 +26,6 @@ exports.newGlobals = function () {
}
}
global.SHUTTING_DOWN_PROCESS = false
/*
We need to count how many process instances we deployd and how many of them have already finished their job, either
because they just finished or because there was a request to stop the proceses. In this way, once we reach the