You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "Charlie Hayes (Jira)" <ji...@apache.org> on 2021/08/17 05:04:00 UTC

[jira] [Updated] (LOG4J2-3137) highlight feature missing escape code

     [ https://issues.apache.org/jira/browse/LOG4J2-3137?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Charlie Hayes updated LOG4J2-3137:
----------------------------------
    Description: 
Using highlight feature:
{code:java}
<Console name="STDOUT" target="SYSTEM_OUT">
 <PatternLayout pattern="%7r %highlight{%-5level}
{FATAL=bg_red white, ERROR=red, WARN=yellow, INFO=normal, DEBUG=black}
%-30c{0} - %msg %throwable%n" alwaysWriteExceptions="true"/>
 </Console>
{code}
Log prints out `[m`, apparently missing `0` before `m`.

Screenshot from TeamCity

!image-2021-08-17-00-01-41-739.png!

 

Seems to work fine in Terminal:

!image-2021-08-17-00-02-06-058.png!

 

and IDEA (I'm also using a line highlighting extension here):

!image-2021-08-17-00-02-27-098.png!

  was:
Using highlight feature:

 
{code:java}
<Console name="STDOUT" target="SYSTEM_OUT">
 <PatternLayout pattern="%7r %highlight{%-5level}
{FATAL=bg_red white, ERROR=red, WARN=yellow, INFO=normal, DEBUG=black}
%-30c{0} - %msg %throwable%n" alwaysWriteExceptions="true"/>
 </Console>
{code}
 

 

 Log prints out `[m`, apparently missing `0` before `m`.

Screenshot from TeamCity

!image-2021-08-17-00-01-41-739.png!

 

Seems to work fine in Terminal:

!image-2021-08-17-00-02-06-058.png!

 

and IDEA (I'm also using a line highlighting extension here):

!image-2021-08-17-00-02-27-098.png!


> highlight feature missing escape code
> -------------------------------------
>
>                 Key: LOG4J2-3137
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-3137
>             Project: Log4j 2
>          Issue Type: Bug
>          Components: Layouts
>    Affects Versions: 2.14.1
>            Reporter: Charlie Hayes
>            Priority: Minor
>         Attachments: image-2021-08-17-00-01-41-739.png, image-2021-08-17-00-02-06-058.png, image-2021-08-17-00-02-27-098.png
>
>
> Using highlight feature:
> {code:java}
> <Console name="STDOUT" target="SYSTEM_OUT">
>  <PatternLayout pattern="%7r %highlight{%-5level}
> {FATAL=bg_red white, ERROR=red, WARN=yellow, INFO=normal, DEBUG=black}
> %-30c{0} - %msg %throwable%n" alwaysWriteExceptions="true"/>
>  </Console>
> {code}
> Log prints out `[m`, apparently missing `0` before `m`.
> Screenshot from TeamCity
> !image-2021-08-17-00-01-41-739.png!
>  
> Seems to work fine in Terminal:
> !image-2021-08-17-00-02-06-058.png!
>  
> and IDEA (I'm also using a line highlighting extension here):
> !image-2021-08-17-00-02-27-098.png!



--
This message was sent by Atlassian Jira
(v8.3.4#803005)