Merge pull request #5600 from gisikw/remove-apdex-check

Remove apdex check from middleware until NR is back
This commit is contained in:
Matteo Pagliazzi 2015-07-12 23:50:35 +02:00
commit fefc8ee732

View file

@ -47,8 +47,8 @@ module.exports.domainMiddleware = function(server,mongoose) {
score = ts[ts.length-1].values.score,
apdexBad = score < .75 || score == 1,
memory = os.freemem() / os.totalmem(),
memoryHigh = false; //memory < 0.1;
if (apdexBad || memoryHigh) throw "[Memory Leak] Apdex="+score+" Memory="+parseFloat(memory).toFixed(3)+" Time="+moment().format();
memoryHigh = memory < 0.1;
if (/*apdexBad || */memoryHigh) throw "[Memory Leak] Apdex="+score+" Memory="+parseFloat(memory).toFixed(3)+" Time="+moment().format();
})
}, mins*60*1000);
}
@ -168,7 +168,7 @@ var getManifestFiles = function(page){
code += '<script type="text/javascript" src="' + getBuildUrl(file) + '"></script>';
});
}
return code;
}
@ -190,7 +190,7 @@ module.exports.locals = function(req, res, next) {
isStaticPage: isStaticPage,
translations: i18n.translations[language.code],
t: function(){ // stringName and vars are the allowed parameters
var args = Array.prototype.slice.call(arguments, 0);
var args = Array.prototype.slice.call(arguments, 0);
args.push(language.code);
return shared.i18n.t.apply(null, args);
},