Get timestamp from logged line

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Get timestamp from logged line

Joan ventusproxy
Hello,

 �

I’m using the following pattern to log lines:

<Pattern>%m%d{yyyy-MM-dd HH:mm:ss.SSS}%n</Pattern>

 �

And writing the line with: this.accessLog.info(variable)

 �

I was wondering if there is any chance to get the timestamp printed in the line (%d{yyyy-MM-dd HH:mm:ss.SSS}) after writing it to the file with the ‘info’ method.

 �

Thanks,

 �

Joan.

Reply | Threaded
Open this post in threaded view
|

Re: Get timestamp from logged line

Ralph Goers


> On Jun 26, 2020, at 10:01 AM, Joan ventusproxy <[hidden email]> wrote:
>
> Hello,
>
> �
>
> I’m using the following pattern to log lines:
>
> <Pattern>%m%d{yyyy-MM-dd HH:mm:ss.SSS}%n</Pattern>
>
> �
>
> And writing the line with: this.accessLog.info(variable)
>
> �
>
> I was wondering if there is any chance to get the timestamp printed in the line (%d{yyyy-MM-dd HH:mm:ss.SSS}) after writing it to the file with the ‘info’ method.

I don’t think I understand what you want.

Ralph




---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]