remove console.error use in many places

the backtraces just flood the logs

apphealthtask: remove console.error
remove spurious console.dir
cleanup scheduler error logging
This commit is contained in:
Girish Ramakrishnan
2020-06-04 09:20:28 -07:00
parent f5fb582f83
commit 50dcf827a5
6 changed files with 19 additions and 28 deletions

View File

@@ -80,7 +80,7 @@ function reconnect(callback) {
gConnectionPool.getConnection(function (error, connection) {
if (error) {
debug('reconnect: unable to reestablish connection to database. Try again in 10 seconds.', error.message);
debug(`reconnect: db connection error. ${error.message} fatal:${error.fatal} code:${error.code}. Will retry in 10 seconds`);
return setTimeout(reconnect.bind(null, callback), 10000);
}
@@ -89,7 +89,7 @@ function reconnect(callback) {
// this function should be invoked only when we have no callbacks pending and we have a fatal error
assert(error.fatal, 'Non-fatal error on connection object');
debug('reconnect: unhandled mysql connection error. Will reconnect in 10 seconds', error);
debug(`reconnect: db connection error. ${error.message} fatal:${error.fatal} code:${error.code}. Will retry in 10 seconds`);
gDefaultConnection = null;