Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@storyous/common-utils

Package Overview
Dependencies
Maintainers
4
Versions
147
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@storyous/common-utils - npm Package Compare versions

Comparing version 1.2.7 to 2.0.0

lib/models/prometheus/prometheusMiddlewares.js

23

lib/models/prometheus/index.js
'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",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc