Logsflags: gm
Java Stack Trace Line
Matches a single Java stack trace frame line.
Try it in RegexProPattern
regexJavaScript
/^\s*at\s+([\w$.]+)\(([^)]+)\)$/gmRaw source: ^\s*at\s+([\w$.]+)\(([^)]+)\)$
How it works
`^\s*at\s+` matches the indent and 'at' keyword. `([\w$.]+)` captures the fully-qualified method. `\(([^)]+)\)$` captures the source location.
Examples
Input
at com.example.MyClass.method(MyClass.java:42)Matches
at com.example.MyClass.method(MyClass.java:42)
Common use cases
- Error triage
- Stack trace parsers
- JVM observability