JSON Parsing
Grepr can automatically detect and parse JSON log messages into structured objects. All fields
in the JSON object are parsed and added into the attributes
field of the log event. Using this along with the
Remapper allows users to enrich their logs.
This operation is automatically performed when creating pipeline through the UI. However, it needs to be explicitly added in the Grepr job graph when creating a pipeline through the API.
Operation execution example:
Incoming log message:
{
"message": "{\"msg\": \"Example log message\", \"@timestamp\": \"2007-12-03T10:15:30.00Z\", \"log\": {\"level\": \"INFO\"}}"
}
Parsed log message:
{
"message": "",
"attributes": {
"@timestamp": "2007-12-03T10:15:30.00Z",
"msg": "Example log message",
"log": {
"level": "INFO"
}
}
}