I am using the following code to scan the output log of the DB Deployment plugin in a post processing script scanner.register("(?i)Executing", function(lineNumber, line) {
I look for the word Executing to get the file name which is on the same line as Executing. This works real well. But there are also ERRORS within the Executing. The ERROR does not have the file name on the line but since it follows the Executing I know whcih file is in error. Is it possible to scan for multiple literals at the same time.
for example log will show
Executing test.txt1
Executing test.txt2
ERROR
Executing test.txt3
So here I know that script 2 is in error since the ERROR follows the Executing.
Answer by pwebster (139) | Nov 18, 2014 at 08:44 AM
You could probably use a similar pattern mentioned in https://developer.ibm.com/answers/questions/163695/how-to-scan-for-a-command-result-that-spans-multip.html#answer-164726
Make a var visible to the scanner callback and keep the current parsed file in it, and update the regex to scan for both kinds of lines. Then if you parse ERROR you have the filename you just processed.
Can I attach external log link in the Process requests log? 1 Answer
UCD output log shows the step(script) log only after the script finishes execution 2 Answers
Maintenance for the contents of \udeploy\logs\store? 2 Answers
Audit log configuration 1 Answer
Generic Process - Manual Task - Output of Resource Name possible? 2 Answers