From 3aeeba02f628bf4f19e8d5b93657fd94a6ef0ec7 Mon Sep 17 00:00:00 2001 From: vince Date: Mon, 19 Mar 2018 15:55:57 +0100 Subject: [PATCH 1/3] fix: remove unused variable when trying to use tracing --- lib/ProcessUtils.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/ProcessUtils.js b/lib/ProcessUtils.js index 3e90117e3..4162fe3fc 100644 --- a/lib/ProcessUtils.js +++ b/lib/ProcessUtils.js @@ -1,9 +1,12 @@ module.exports = { injectModules: function() { + console.log(process.env.pmx) if (process.env.pmx !== 'false') { const pmx = require('pmx'); + console.log('-------------------------------------------------') + console.log(process.env.km_link,process.env.trace, process.env.deep_monitoring) pmx.init({ - transactions: (process.env.km_link === 'true' && (process.env.trace === 'true' || process.env.deep_monitoring === 'true')) || false, + transactions: (process.env.trace === 'true' || process.env.deep_monitoring === 'true') || false, http: process.env.km_link === 'true' || false, v8: process.env.v8 === 'true' || process.env.deep_monitoring === 'true' || false, event_loop_dump: process.env.event_loop_inspector === 'true' || process.env.deep_monitoring === 'true' || false, From 33db5084814ae7940c90b7f933f9514d28008b78 Mon Sep 17 00:00:00 2001 From: vince Date: Mon, 19 Mar 2018 16:24:48 +0100 Subject: [PATCH 2/3] chore: remove unused console.log --- lib/ProcessUtils.js | 3 --- test/interface/bus.fork.spec.mocha.js | 1 - 2 files changed, 4 deletions(-) diff --git a/lib/ProcessUtils.js b/lib/ProcessUtils.js index 4162fe3fc..5d32750b4 100644 --- a/lib/ProcessUtils.js +++ b/lib/ProcessUtils.js @@ -1,10 +1,7 @@ module.exports = { injectModules: function() { - console.log(process.env.pmx) if (process.env.pmx !== 'false') { const pmx = require('pmx'); - console.log('-------------------------------------------------') - console.log(process.env.km_link,process.env.trace, process.env.deep_monitoring) pmx.init({ transactions: (process.env.trace === 'true' || process.env.deep_monitoring === 'true') || false, http: process.env.km_link === 'true' || false, diff --git a/test/interface/bus.fork.spec.mocha.js b/test/interface/bus.fork.spec.mocha.js index 3ed46921f..31e98f7a5 100644 --- a/test/interface/bus.fork.spec.mocha.js +++ b/test/interface/bus.fork.spec.mocha.js @@ -89,7 +89,6 @@ describe('PM2 BUS / RPC', function() { var plan = new Plan(2, done); pm2_bus.on('*', function(event, data) { - console.log(event); if (event == 'process:event') { event.should.eql('process:event'); data.should.have.properties(PROCESS_EVENT); From 23fd8ecfea9b2bf61359f62a8e6e1a582c3b0d6e Mon Sep 17 00:00:00 2001 From: vince Date: Mon, 19 Mar 2018 16:40:16 +0100 Subject: [PATCH 3/3] test: fix test with km_link --- test/interface/pm2.link.check.mocha.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/interface/pm2.link.check.mocha.js b/test/interface/pm2.link.check.mocha.js index 6bc24e6b2..8bec60293 100644 --- a/test/interface/pm2.link.check.mocha.js +++ b/test/interface/pm2.link.check.mocha.js @@ -37,7 +37,7 @@ describe('PM2 link variable checks', function() { setTimeout(function() { pm2.list(function(err, dt) { dt[0].pm2_env.km_link.should.be.false(); - dt[0].pm2_env.axm_options.transactions.should.be.false(); + dt[0].pm2_env.axm_options.transactions.should.be.true(); done(); }); }, 500);