Howdy,

>Good question! Sorry I did not include it. I am looking for something
>similar to swatch, but can handle the multiple-lined errors. I would
>want the program to have some sort of rules setting functionality
>(preferably regex) and that allows actions based upon the specified
>rules.

OK.  I actually went and looked at the Swatch page out of interest.
Cool tool.

Here's an approach that may work for you: use log4j.  Implement a
TriggeringEventEvaluator
(http://jakarta.apache.org/log4j/docs/api/org/apache/log4j/spi/Triggerin
gEventEvaluator.html) to do the regex or whatever rules you want to
decide required a page from a log message.  The evaluator will get every
log message, including its complete stack trace and any details you want
to add.  You can use log4j's MDC
(http://jakarta.apache.org/log4j/docs/api/org/apache/log4j/MDC.html) to
provide any details needed in order to decide whether the event merits a
message to your page or not.

Log4j comes with an SMTP appender that sends email and has all the logic
you want: throttling and arbitrary rules for even evaluation.  See
http://jakarta.apache.org/log4j/docs/api/org/apache/log4j/net/SMTPAppend
er.html for details.

Log4j doesn't come with a pager appender right now.  You could use a JMS
appender to send events (that pass the triggering event evaluator's
criteria) to a JMS server somewhere, as there are J2EE servers that can
handle paging.  Alternatively, you can write the pager appender yourself
and maybe even donate it to us as a log4j contribution ;)

This may seem like a lot, but it's really more work explaining the
process than doing it ;)

Yoav Shapira
Millennium ChemInformatics



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to