chatty

Sexy syslogging for node.js

Chatty

Sexy syslogging for node.js

npm install chatty
var chatty = require('chatty');
 
chatty.info('Hello');
var express = require('express');
var chatty = require('chatty');
 
app.use(express.logger({ stream: chatty.stream() }));
 
app.get('/', function (reqres) {
  res.send('Hello');
});
 
app.listen(3000);

Syslog with LOG_INFO priority

Syslog with LOG_ERR priority

Syslog with LOG_DEBUG priority

Return a syslog stream wrapper with specified priority.

priority can be either a syslog priority or any of the strings: info, error or debug. (LOG_INFO by default)

options is merged with the default and passed into the stream constructor

Configure chatty, availiable options are: ident, option and facility (syslog man page

Direct wrapper of syslog (you probably don't want this).

priority must be a syslog.prority int