This package has been deprecated

    Author message:

    This package has been replaced by @financial-times/n-logger

    ft-next-logger

    4.3.1 • Public • Published

    Next Logger Circle CI

    Logging utility

    Usage

    var logger = require('ft-next-logger').logger;
    logger.info('Saying hello');
    logger.warn('Everything’s mostly cool');
    logger.error('Uh-oh', { field: 'some value' });
    

    Loggers

    By default

    • the console logger is added
      • logs to error if NODE_ENV === test
      • otherwise logger level is set by CONSOLE_LOGGER_LEVEL environment variable, or is set to silly by default
    • the splunk logger is added if NODE_ENV === production

    API

    • logger - the Winston object
    • addConsole(level = 'info', opts = {})
    • removeConsole()
    • addSplunk(splunkUrl, level = 'info', opts = {})
    • removeSplunk()
    • clearLoggers()

    Releasing

    $ make release version=patch
    

    Version also accepts minor and major

    Keywords

    none

    Install

    npm i ft-next-logger

    DownloadsWeekly Downloads

    76

    Version

    4.3.1

    License

    MIT

    Last publish

    Collaborators

    • financial-times
    • ftlabs
    • ironsidevsquincy
    • mattandrews