Przeglądaj źródła

set build version via env var and bump build version

Henry Oswald 7 lat temu
rodzic
commit
425a6f55ff

+ 4 - 2
libraries/metrics/metrics.coffee

@@ -22,12 +22,14 @@ module.exports = Metrics =
 		appname = _name
 		collectDefaultMetrics({ timeout: 5000, prefix: Metrics.buildPromKey()})
 		if process.env['ENABLE_TRACE_AGENT'] == "true"
-			traceAgent.start()
+			traceOpts =
+				ignoreUrls: [/^\/status/, /^\/health_check/] 
+			traceAgent.start(traceOpts)
 		debugAgent.start({
 			serviceContext: {
 				allowExpressions: true,
 				service: appname,
-				version: '0.0.1'
+				version: process.env['BUILD_VERSION']
 			}
 		})
 		Metrics.inc("process_startup")

+ 1 - 1
libraries/metrics/package.json

@@ -1,6 +1,6 @@
 {
   "name": "metrics-sharelatex",
-  "version": "2.0.8",
+  "version": "2.0.9",
   "description": "A drop-in metrics and monitoring module for node.js apps",
   "repository": {
     "type": "git",