pino-airbrake-transport
v1.1.1
Published
Airbrake Transport for Pino
Downloads
28
Readme
Pino Airbrake transport
This module provides a transport for Pino that sends errors to Airbrake.
Thanks to this module you can automatically transmit logs, stacktrace and context from pino to Aibrake.io. The best part is that this happens in a worker thread so that the impact of logging is reduced to the minimum.
Install
npm
npm i pino-airbrake-transport
yarn
yarn add pino-airbrake-transport
Usage
import pino from "pino";
const logger = pino({
transport: {
target: "pino-airbrake-transport",
options: {
airbrake: {
projectId: 1,
projectKey: "REPLACE_ME",
environment: "production",
// aditional options for airbrake
performanceStats: false,
},
},
level: "info", // minimum log level that should be sent to Airbrake
},
});
Credits
Originally forked from tomer-yechie's Sentry implementation