All Versions
110
Latest Version
Avg Release Cycle
22 days
Latest Release
-

Changelog History
Page 6

  • v0.21.3 Changes

    • [issue #90] Fix bunyan -p '*' breakage in version 0.21.2.
  • v0.21.2 Changes

    ๐Ÿš€ Note: Bad release. The switchrate change below broke bunyan -p '*' usage ๐Ÿ‘€ (see issue #90). Use 0.21.3 or later.

    • [issue #88] Should be able to efficiently combine "-l" with "-p *".

    • Avoid DTrace buffer filling up, e.g. like this:

      $ bunyan -p 42241 > /tmp/all.log
      dtrace: error on enabled probe ID 3 (ID 75795: bunyan42241:mod-87ea640:log-trace:log-trace): out of scratch space in action #1 at DIF offset 12
      dtrace: error on enabled probe ID 3 (ID 75795: bunyan42241:mod-87ea640:log-trace:log-trace): out of scratch space in action #1 at DIF offset 12
      dtrace: 138 drops on CPU 4
      ...
      

    From Bryan: "the DTrace buffer is filling up because the string size is so large... by increasing the switchrate, you're increasing the rate at which that buffer is emptied."

  • v0.21.1 Changes

    • ๐Ÿ‘ [pull #83] Support rendering 'client_res' key in bunyan CLI (by github.com/mcavage).
  • v0.21.0 Changes

    • 'make check' clean, 4-space indenting. No functional change here, just lots of code change.
    • [issue #80, #82] Drop assert that broke using 'rotating-file' with a default period (by github.com/ricardograca).
  • v0.20.0 Changes

    • [Slight backward incompatibility] Fix serializer bug introduced in 0.18.3 (see below) to only apply serializers to log records when appropriate.

    This also makes a semantic change to custom serializers. Before this change a serializer function was called for a log record key when that value was truth-y. The semantic change is to call the serializer function as long as the value is not undefined. That means that a serializer function should handle falsey values such as false and null.

    • โšก๏ธ Update to latest 'mv' dep (required for rotating-file support) to support node v0.10.0.
  • v0.19.0 Changes

    โš  WARNING: This release includes a bug introduced in bunyan 0.18.3 (see โฌ†๏ธ below). Please upgrade to bunyan 0.20.0.

    • 0๏ธโƒฃ [Slight backward incompatibility] Change the default error serialization (a.k.a. bunyan.stdSerializers.err) to not serialize all additional attributes of the given error object. This is an open door to unsafe logging and logging should always be safe. With this change, error serialization will log these attributes: message, name, stack, code, signal. The latter two are added because some core node APIs include those fields (e.g. child_process.exec).

    Concrete examples where this has hurt have been the "domain" change necessitating 0.18.3 and a case where node-restify uses an error object as the response object. When logging the err and res in the same log statement (common for restify audit logging), the res.body would be JSON stringified as '[Circular]' as it had already been emitted for the err key. This results in a WTF with the bunyan CLI because the err.body is not rendered.

    If you need the old behaviour back you will need to do this:

        var bunyan = require('bunyan');
        var errSkips = {
            // Skip domain keys. `domain` especially can have huge objects that can
            // OOM your app when trying to JSON.stringify.
            domain: true,
            domain_emitter: true,
            domain_bound: true,
            domain_thrown: true
        };
        bunyan.stdSerializers.err = function err(err) {
           if (!err || !err.stack)
               return err;
           var obj = {
               message: err.message,
               name: err.name,
               stack: getFullErrorStack(err)
           }
           Object.keys(err).forEach(function (k) {
               if (err[k] !== undefined && !errSkips[k]) {
                   obj[k] = err[k];
               }
           });
           return obj;
         };
    
    • 0๏ธโƒฃ "long" and "bunyan" output formats for the CLI. bunyan -o long is the default format, the same as before, just called "long" now instead of the cheesy "paul" name. The "bunyan" output format is the same as "json-0", just with a more convenient name.
  • v0.18.3 Changes

    โš  WARNING: This release introduced a bug such that all serializers are ๐ŸŒฒ applied to all log records even if the log record did not contain the key for that serializer. If a logger serializer function does not handle โš  being given undefined, then you'll get warnings like this on stderr:

    bunyan: ERROR: This should never happen. This is a bug in <https://github.com/trentm/node-bunyan> or in this application. Exception from "foo" Logger serializer: Error: ...
        at Object.bunyan.createLogger.serializers.foo (.../myapp.js:20:15)
        at Logger._applySerializers (.../lib/bunyan.js:644:46)
        at Array.forEach (native)
        at Logger._applySerializers (.../lib/bunyan.js:640:33)
        ...
    

    ๐ŸŒฒ and the following junk in written log records:

    "foo":"(Error in Bunyan log "foo" serializer broke field. See stderr for details.)"
    

    โฌ†๏ธ Please upgrade to bunyan 0.20.0.

    • Change the bunyan.stdSerializers.err serializer for errors to exclude the "domain*" keys. err.domain will include its assigned members which can arbitrarily large objects that are not intended for logging.

    • ๐Ÿ‘‰ Make the "dtrace-provider" dependency optional. I hate to do this, but installing bunyan on Windows is made very difficult with this as a required dep. Even though "dtrace-provider" stubs out for non-dtrace-y platforms, without a compiler and Python around, node-gyp just falls over.

  • v0.18.2 Changes

    • ๐Ÿšš [pull #67] Remove debugging prints in rotating-file support. (by github.com/chad3814).
    • โšก๏ธ Update to [email protected].
  • v0.18.1 Changes

    • Get the bunyan CLI to not automatically page (i.e. pipe to less) if stdin isn't a TTY, or if following dtrace probe output (via -p PID), or if not given log file arguments.
  • v0.18.0 Changes

    • ๐ŸŒฒ Automatic paging support in the bunyan CLI (similar to git log et al). IOW, bunyan will open your pager (by default less) and pipe rendered log output through it. A main benefit of this is getting colored logs with a pager without the pain. Before you had to explicit use --color to tell bunyan to color output when the output was not a TTY:

      bunyan foo.log --color | less -R        # before
      bunyan foo.log                          # now
      

    Disable with the --no-pager option or the BUNYAN_NO_PAGER=1 environment variable.

    Limitations: Only supported for node >=0.8. Windows is not supported (at least not yet).

    • โœ… Switch test suite to nodeunit (still using a node-tap'ish API via a helper).