Cleaning feature not needed
This commit is contained in:
1 parent
ddde43d7d7
commit
cf5e137c0f
6 files changed
+5
-23
No files matched your search
+1
-1
@@ -6,7 +6,7 @@ REQUIRED_PROJECTS_PATH=../Projects
|
||||
PROJECTS_PATH=../Projects
|
||||
|
||||
USE_KEYVAULT=false
|
||||
WRITE_LOGS_TO_FILES=true
|
||||
|
||||
LOG_PATH=../Log-Files
|
||||
|
||||
WEB_SOCKETS_INTERFACE_PORT=18041
|
||||
|
||||
@@ -27,19 +27,11 @@ exports.newGlobals = function () {
|
||||
}
|
||||
|
||||
global.SHUTTING_DOWN_PROCESS = false
|
||||
|
||||
|
||||
|
||||
require('dotenv').config();
|
||||
|
||||
global.WRITE_LOGS_TO_FILES = process.env.WRITE_LOGS_TO_FILES
|
||||
|
||||
/*
|
||||
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
|
||||
amount of instances started, we can safelly destroy the rest of the objects running and let this nodejs process die.
|
||||
*/
|
||||
|
||||
global.ENDED_PROCESSES_COUNTER = 0
|
||||
global.TOTAL_PROCESS_INSTANCES_CREATED = 0
|
||||
|
||||
|
||||
@@ -702,9 +702,7 @@
|
||||
logger.write(MODULE_NAME, "[INFO] run -> loop -> loopControl -> Restarting Loop in " + (processConfig.normalWaitTime / 1000) + " seconds.")
|
||||
nextLoopTimeoutHandle = setTimeout(loop, processConfig.normalWaitTime);
|
||||
processHeartBeat(undefined, undefined, "Waiting " + processConfig.normalWaitTime / 1000 + " seconds for next execution.")
|
||||
if (global.WRITE_LOGS_TO_FILES === 'true') {
|
||||
logger.persist();
|
||||
}
|
||||
logger.persist();
|
||||
}
|
||||
break;
|
||||
case 'Retry': {
|
||||
|
||||
@@ -529,10 +529,7 @@ exports.newLearningBot = function newLearningBot(bot, parentLogger) {
|
||||
|
||||
function onStop() {
|
||||
if (FULL_LOG === true) { logger.write(MODULE_NAME, "[INFO] run -> loop -> loopControl -> onStop -> Stopping the Loop Gracefully. See you next time!"); }
|
||||
|
||||
if (global.WRITE_LOGS_TO_FILES === 'true') {
|
||||
logger.persist();
|
||||
}
|
||||
logger.persist();
|
||||
|
||||
global.EVENT_SERVER_CLIENT_MODULE.raiseEvent(bot.sessionKey, 'Stopped')
|
||||
processStopped()
|
||||
|
||||
@@ -498,9 +498,7 @@
|
||||
logger.write(MODULE_NAME, "[INFO] run -> loop -> loopControl -> Restarting Loop in " + (processConfig.normalWaitTime / 1000) + " seconds.")
|
||||
nextLoopTimeoutHandle = setTimeout(loop, processConfig.normalWaitTime);
|
||||
processHeartBeat(undefined, undefined, "Waiting " + processConfig.normalWaitTime / 1000 + " seconds for next execution.")
|
||||
if (global.WRITE_LOGS_TO_FILES === 'true') {
|
||||
logger.persist();
|
||||
}
|
||||
logger.persist();
|
||||
}
|
||||
break;
|
||||
case 'Retry': {
|
||||
|
||||
@@ -529,10 +529,7 @@
|
||||
|
||||
function onStop() {
|
||||
logger.write(MODULE_NAME, "[INFO] run -> loop -> loopControl -> onStop -> Stopping the Loop Gracefully. See you next time!")
|
||||
|
||||
if (global.WRITE_LOGS_TO_FILES === 'true') {
|
||||
logger.persist();
|
||||
}
|
||||
logger.persist();
|
||||
|
||||
global.EVENT_SERVER_CLIENT_MODULE.raiseEvent(bot.TRADING_SESSIONKey, 'Stopped')
|
||||
processStopped()
|
||||
|
||||
Reference in new issue
Block a user