I am using the Jenkins Log Parser Plugin as a post-build step to check for errors after builds
I have all my rules in a file and the notation supports the Java regex embedded flag expression:
# list keywords or regex for ERRORS:
error /(?i)error/
error / (?i)error/
error /(?i)error /
error / (?i)error /
error /(?i)error:/
error / (?i)error:/
error /(?i)error: /
error / (?i)error: /
error /Unknown database/
error /Connect failed/
error /(?i)undefined/
error /Call Stack:/
# list keywords or regex for WARNINGS:
warning /(?i)^warning/
warning /(?i)warning/
warning /(?i)warning:/
My problem is that I am not so good with regex expressions, and every time it encounters a word that contains "error" it triggers an alarm. For example: T**error** or Biot**error** (and I know it may come from my bad expressions, but if I mark "Bioterror" or "Terror" as warning, it still overwrites them as errors and triggers the alarm).
My questions are:
what is the proper way to exclude certain words defined by me?
is this achievable? (I thought this is the way the plugin works, since if I mark the necessary words as warnings it still highlights them as errors)