pino-udp
v1.0.1
Published
A pino 'transport' for writing to a udp socket
Downloads
3
Readme
pino-udp-transport
Simple udp transport for logger Pino
This module provides a "transport" for pino that simply forwards messages to an arbitrary socket. The socket can be UDPv4.
You should install pino-udp
for ease of use:
$ npm install pino-udp
Example
const pino = require('pino');
const udpTransport = require('pino-udp');
let options = {
level: 'info'
};
let logger = pino(options, new udpTransport({
address: '127.0.0.1',
port: 12201,
}));
logger.info('test to udp');