Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
Golang

`
(\[(?P<datetime>.+)\]\[(?P<thread>[^\]]+)\])?(?P<subsystem>.+?):\s*((?P<level>Fatal|Error|Warning|Log):\s?)?(?P<msg>.+)
`
gm

Description

This regex is suitable for anyone ingesting UE_LOG files into Loki and creating dashboards in Grafana.

Submitted by Mike McShaffry - 3 years ago