@storyous/common-utils
Advanced tools
Comparing version 1.2.7 to 2.0.0
'use strict'; | ||
const promClient = require('prom-client'); | ||
const prometheusMiddlewares = require('./prometheusMiddlewares'); | ||
const prometheus = { | ||
httpRequest: null, | ||
middlewares: prometheusMiddlewares | ||
register: null, | ||
init () { | ||
this.register = new promClient.Registry(); | ||
promClient.collectDefaultMetrics({ register: this.register }); | ||
this.httpRequest = new promClient.Counter({ | ||
name: 'httpRequest', | ||
help: 'Query tracking', | ||
labelNames: ['name', 'query', 'status', 'message', 'originalUrl'], | ||
registers: [this.register] | ||
}); | ||
} | ||
}; | ||
module.exports = prometheus; |
{ | ||
"name": "@storyous/common-utils", | ||
"version": "1.2.7", | ||
"version": "2.0.0", | ||
"description": "Common utils for storyous microservices", | ||
@@ -23,2 +23,3 @@ "main": "lib/index.js", | ||
"mongodb": "^2.2.9", | ||
"node-fetch": "^2.1.2", | ||
"nodemailer": "^4.4.2", | ||
@@ -25,0 +26,0 @@ "prom-client": "^11.0.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
49743
28
1561
9
3
+ Addednode-fetch@^2.1.2
+ Addednode-fetch@2.7.0(transitive)
+ Addedtr46@0.0.3(transitive)
+ Addedwebidl-conversions@3.0.1(transitive)
+ Addedwhatwg-url@5.0.0(transitive)