You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "Geng Yuanzhe (Jira)" <ji...@apache.org> on 2020/09/09 18:25:00 UTC
[jira] [Commented] (LOG4J2-2889) Data-Time Formate in HTML Layout
[ https://issues.apache.org/jira/browse/LOG4J2-2889?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17193111#comment-17193111 ]
Geng Yuanzhe commented on LOG4J2-2889:
--------------------------------------
[~rgoers]
Hello, I'm trying to solve this problem. I add a new parameter *datePattern* for @PluginFactory method of HtmlLayout, and use DatePatternConverter.newInstance(new String[]\{datePattern}) to create the converter. My question is should I create another parameter for the timezone? Or combine the dataPattern and timezone as one parameter for @PluginFactory method. If combining to one parameter is suggested, what rule should I use?
> Data-Time Formate in HTML Layout
> --------------------------------
>
> Key: LOG4J2-2889
> URL: https://issues.apache.org/jira/browse/LOG4J2-2889
> Project: Log4j 2
> Issue Type: Bug
> Components: Layouts
> Affects Versions: 2.13.3
> Reporter: karthikeyan Mourougane
> Priority: Blocker
> Labels: easyfix
> Fix For: 2.13.3
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> Hi Team,
> As per the documentation we have set the HTML layout as below:
> {{<HTMLLayout charset=}}{{"UTF-8"}} {{title=}}{{"Test Logs"}} {{locationInfo=}}{{"true"}} {{/>}}
> {{ }}
> In the HTML page, time stamp is not in proper format:
> ||Time||Thread||Level||Logger||Message||
> |350350462|HTTP Handler 10.170.233.124|{color:#993300}*WARN*{color}|adminServer|
> How to change date time format to custom timestamp.
>
> Thanks
> Karthick
--
This message was sent by Atlassian Jira
(v8.3.4#803005)