Skip to content

Latest commit

 

History

History
46 lines (30 loc) · 654 Bytes

README.zh_CN.md

File metadata and controls

46 lines (30 loc) · 654 Bytes

egg-swagger-stats

swagger-stats egg插件, 支持cluster模式获取所有metrics.

Install

$ npm i egg-swagger-stats --save

Usage

// {app_root}/config/plugin.js
exports.eggSwaggerStats = {
  enable: true,
  package: 'egg-swagger-stats',
};

Configuration

// {app_root}/config/config.default.js
exports.eggSwaggerStats = {
};

see swaggerstats.io for more detail.

Example

打开浏览器访问以下地址:
metrics: /host:port/swagger-stats/metrics
     ui: /host:port/swagger-stats/ui

推荐使用prometheus采集metrics.

License

MIT