Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8288298 Resolve multiline message parsing ambiguities in UL
  3. JDK-8343757

Release Note: Decorate Newlines in Unified Logging Multiline Messages

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Delivered
    • Icon: P4 P4
    • 24
    • 24
    • hotspot

      Unified Logging now outputs a special empty decorator `[ ]` followed by a space after newlines in multiline log messages. This change allows unambiguous parsing of Unified Logging output.

      To illustrate the change, consider the output of `log_info(gc)("A\n[gc] B");`:
      ```
      [gc] A
      [ ] [gc] B
      ```
      It is possible to parse this multiline message unambiguously. This was previously not possible, as the output was
      ```
      [gc] A
      [gc] B
      ```
      which could (and likely would be) parsed as two distinct log messages `A` and `B`.

      Tools that currently deal with multiline parsing ambiguities in Unified Logging require an update. The updates will likely result in simpler and more robust implementations.

            dlunden Daniel Lunden
            dlunden Daniel Lunden
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: