On 6/29/05, Curt Arnold <[EMAIL PROTECTED]> wrote: > There was a somewhat related request on the slf4j-dev mailing list to > have an "ignore" level (http://www.slf4j.org/pipermail/dev/2005-June/ > 000127.html) for expected exceptions. For us, I think the most > reasonable approach is to provide some configuration in the stock > PatternLayout to configure a threshold below which stack traces are > not expanded
This would be great, being able to tell the layout to drop stackTraces with X threshold, or maybe set a limit of stack trace lines. (for example, every exception in a Tomcat-hosted webapp will run a page or two of stack trace lines getting to the root cause of the exception - I'd love being able to limit the stack trace that way: from just the exception type to the full-blown stack trace). I achieved a rough solution of this by subclassing PatternLayout and returning false in ignoresThrowable(), as pointed out in my previous post. It seems most sensible to apply this at Layout level, so that another appender that does have an interest in the stack traces can be attached to the same Logger. cheers and thanks for the link, it was very interesting -- Javier Gonzalez Nicolini --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
