Nice Parakeet Marriage

    filebeat-logger
    TypeScript icon, indicating that this package has built-in type declarations

    1.2.0 • Public • Published

    A winston logger that prints json lines in elastic common schema format

    build Known Vulnerabilities npm license

    Quality Gate Status Maintainability Rating Reliability Rating Security Rating

    Coverage Code Smells Duplicated Lines (%)


    Install

    npm install --save filebeat-logger

    Usage

    const filebeatLogger = require('filebeat-logger')
    const logger = filebeatLogger.create({
        logLevel: 'debug', // 'info' by default
        printTimestamp: true, // false by default
        keysOrder: ['@timestamp', 'message'], // ["@timestamp", "message", "log.level"] by default
        stderrLevels: ['warn', 'error'], // ["error", "warn", "warning"] by default
    });
    
    logger.info('I am an info message')
    // {"@timestamp":"2022-01-30T14:49:00.323Z","message": "I am an info message","log.level":"info"}

    Install

    npm i filebeat-logger

    DownloadsWeekly Downloads

    52

    Version

    1.2.0

    License

    MIT

    Unpacked Size

    28.4 kB

    Total Files

    13

    Last publish

    Collaborators

    • firecow