mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-23 19:04:14 +00:00
add some logging in
This commit is contained in:
parent
c257482e15
commit
9eac49ad84
1 changed files with 5 additions and 1 deletions
|
@ -19,15 +19,19 @@ module.exports = Metrics =
|
|||
initialize: (_name) ->
|
||||
appname = _name
|
||||
collectDefaultMetrics({ timeout: 5000, prefix: Metrics.buildPromKey()})
|
||||
|
||||
|
||||
logger.log("ENABLE_TRACE_AGENT set to #{process.env['ENABLE_TRACE_AGENT']}")
|
||||
if process.env['ENABLE_TRACE_AGENT'] == "true"
|
||||
logger.log("starting google trace agent")
|
||||
traceAgent = require('@google-cloud/trace-agent')
|
||||
|
||||
traceOpts =
|
||||
ignoreUrls: [/^\/status/, /^\/health_check/]
|
||||
traceAgent.start(traceOpts)
|
||||
|
||||
logger.log("ENABLE_DEBUG_AGENT set to #{process.env['ENABLE_DEBUG_AGENT']}")
|
||||
if process.env['ENABLE_DEBUG_AGENT'] == "true"
|
||||
logger.log("starting google debug agent")
|
||||
debugAgent = require('@google-cloud/debug-agent')
|
||||
debugAgent.start({
|
||||
serviceContext: {
|
||||
|
|
Loading…
Reference in a new issue