Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-2703

MapMessage#getFormattedMessage() incorrectly formats Object's

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 2.13.1
    • None
    • None

    Description

      The following code snippet

      new MapMessage()
              .with("key1", "val1")
              .with("key2", Collections.singletonMap("val2.1", "val2.2"))
              .getFormattedMessage(new String[]{"JSON"});

      produces

      {"key1":"val1", "key2":"{val2.1=val2.2}"}

      whereas

      {"key1":"val1", "key2":{"val2.1":"val2.2}"}

      was expected.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              vy Volkan Yazici
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m