egg-logger-sentry
v2.3.3
Published
Logger transport for Sentry
Downloads
35
Maintainers
Readme
egg-logger-sentry
Sentry SDK for Egg
Install
$ npm i egg-logger-sentry --save
Configuration
Change ${app_root}/config/plugin.js
to enable egg-logger-sentry
plugin:
exports.loggerSentry = {
enable: true,
package: 'egg-logger-sentry',
};
Configure information in ${app_root}/config/config.default.js
:
exports.loggerSentry = {
dsn: 'https://<hash>@sentry.example.com/<id>'
};
see config/config.default.js for more detail.
Usage
ctx.logger.debug('debug info');
ctx.logger.info('some request data: %j', ctx.request.body);
ctx.logger.warn('WARNNING!!!!');
Questions & Suggestions
Please open an issue here.