I am new to regular expression, please kindly help me on the error scenario where I need to use regex to match two error messages (appearing in different lines, but same paragraph) in AND condition from a log file:
Msg1 - ERROR [com.company.util.ejb.TimedBean] () FAILED processing Loader
Msg2 - java.lang.RuntimeException: Message code:[SL] is unknown.
Basically, what I need is to match (msg1)&&(msg2), in this case, (ERROR...Loader) will appear in the first line and (java...unknown) will follow in the next line. The messages will always follow this order. I am not programming in any typical language here, they will be put into a enterprise tool that accepts regexp.
If possible, would you also show me how to make it in Or condition as (msg1)||(msg2)?