Browse Source
logging cleanup; error page display improvements;
fix-133-memory-crash
Dan Janosik
6 years ago
No known key found for this signature in database
GPG Key ID: C6F8CE9FFDB2CED2
2 changed files with
4 additions and
4 deletions
-
app.js
-
views/error.pug
|
|
@ -521,8 +521,6 @@ app.use(function(req, res, next) { |
|
|
|
var time = Date.now() - req.startTime; |
|
|
|
var memdiff = process.memoryUsage().heapUsed - req.startMem; |
|
|
|
|
|
|
|
console.log(`Heapdiff: path=${req.path}, heapdiff=${memdiff}`); |
|
|
|
|
|
|
|
if (global.influxdb) { |
|
|
|
var points = []; |
|
|
|
points.push({ |
|
|
|
|
|
@ -5,10 +5,12 @@ block content |
|
|
|
hr |
|
|
|
|
|
|
|
if (message) |
|
|
|
p !{message} |
|
|
|
pre |
|
|
|
code(class="json bg-light") !{message} |
|
|
|
else |
|
|
|
p Unknown error |
|
|
|
|
|
|
|
if (error) |
|
|
|
h2 #{error.status} |
|
|
|
pre #{error.stack} |
|
|
|
pre |
|
|
|
code(class="json bg-light") #{error.stack} |
|
|
|