added heapdump endpoint

This commit is contained in:
Henry Oswald 2015-11-30 16:16:16 +00:00
parent 4fa38178be
commit 69734c20c0
2 changed files with 6 additions and 1 deletions

View file

@ -122,6 +122,10 @@ apiRouter.get "/profile", (req, res) ->
res.json(profile)
, time
app.get "/heapdump", (req, res)->
require('heapdump').writeSnapshot '/tmp/' + Date.now() + '.clsi.heapsnapshot', (err, filename)->
res.send filename
logger.info ("creating HTTP server").yellow
server = require('http').createServer(app)

View file

@ -23,6 +23,7 @@
"dateformat": "1.0.4-1.2.3",
"express": "4.13.0",
"express-session": "1.11.3",
"heapdump": "^0.3.7",
"http-proxy": "^1.8.1",
"jade": "~1.3.1",
"ldapjs": "^0.7.1",
@ -74,6 +75,6 @@
"sandboxed-module": "0.2.0",
"sinon": "",
"timekeeper": "",
"grunt-env":"0.4.4"
"grunt-env": "0.4.4"
}
}