-
Bug
-
Resolution: Not A Defect
-
Minor
-
Ubuntu Linux
Regular expression is unable to figure out error pattern.
This bug is in follow up of thread : https://groups.google.com/forum/#!topic/jenkinsci-users/uWI6SU9GVQg
Global configuration
Name: Puppet-Error-Parser Link name: Puppet-Error-Parser Tredn report name : Puppet Error Trend Regular Expression: ^.*(err:) (.*)at(.*\.pp):(\d+)$
Mapping script:
import hudson.plugins.warnings.parser.Warning String category = matcher.group(1) String message = matcher.group(2) String fileName = matcher.group(3) String lineNumber = matcher.group(4) return new Warning(fileName, Integer.parseInt(lineNumber), "Dynamic Parser", category, message);
Example Log Message:
19:35:11 err: Could not parse for environment production: Syntax error at '{'; expected '}' at /home/build/jenkins/workspace/puppet-parser-try/modules/profile/manifests/mongodb/abc/shard/master.pp:5
output of regular expression matching
One warning found
file name: /home/build/jenkin[...]ongodb/abc/shard/master.pp
line number: 5
priority: Normal Priority
category: err:
type: Dynamic Parser
message: Could not parse for [...]apos;; expected '}'
Attached the parser definition
that I'm using on my machine.