Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pattern parser does not support messages including [] characters #563

Open
donatelloOo opened this issue Jun 24, 2019 · 0 comments
Open

Comments

@donatelloOo
Copy link

Hello,

Here is a recurrent issue we encounter when our message contains square brackets like in the example below:

Log parser:

type=log4j
pattern=[TIMESTAMP][LEVEL][THREAD][LOGGER][LINE]MESSAGE
dateFormat=yyyy-MM-dd HH:mm:ss,SSS
name=Standard Parser
charset=UTF-8

Log file:

[2019-06-18 14:46:53,522][TRACE][T-X][com.company.product.TheClass][ 257]a message
[2019-06-18 14:46:54,087][TRACE][T-Y][com.company.product.TheClass][ 558]another mesage with output: [MyObject][7714][20190611.0]
[2019-06-18 14:46:55,568][TRACE][T-X][com.company.product.TheClass][ 257]a last message

The result is invalid mapping as below:

Date:    2019-06-18 14:46:54.087
Class:   ?
Method:  ?
Level:     DEBUG
Thread:  558]another mesage with output: [MyObject
File:    ?:20190611.0
Logger:  7714

Message: com.company.product.TheClass

This is very inconvenient as filters obviously won't work for these messages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant