An library providing utility method to log to either using log4js or fluentd
npm install git://github.com/SanthoshVasabhaktula/node-logger.git
var Logger = require('node-logger');
Logger.log("log to console");
Logger.log({log: "log to console"}); // To log a json object
Logger.configure('log4js', {appender: { type: 'file', filename: 'logs/test.log', category: 'test'}});
Logger.log("Log to log4j 1");
Logger.configure('fluentd', {tag: 'performance', host: 'localhost', port: 24224, timeout: 3.0});
Logger.log({data:"logging to fluentd 1"});
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.
- 0.1.0 Initial release