I think this could be a good feature, but I guess will have to code it yourself. You could write your own Layout class or extend e.g. PatternLayout. Let ignoresThrowable() return false, and handle the throwable yourself. You will have to construct the magic that filters the lines, maybe by instantiating an implementation of ObjectRenderer that renders a Throwable, or by defining the filtering with a pattern similar to the formatting patterns, e.g. %-3T could mean "show the 3 first lines of the Throwable stack trace".
-- Thomas | -----Original Message----- | From: Leos Literak [mailto:[EMAIL PROTECTED]] | Sent: 29 July 2002 08:52 | To: [EMAIL PROTECTED] | Subject: filtered exception logging | | | Hi, | | I am interested, if there is any way ho to filter | out some parts of exception trace. | | Eg. I am interested in exceptions in my code, | other calls are not interesting for me. | | See the difference: | | 2002-07-26 04:03:27,325 ERROR AbcServlet - Cannot display page | http://www.abclinuxu.cz:8080/clanky/ViewRelation | java.lang.Exception: Relation is null! | at | cz.abclinuxu.servlets.view.ViewRelation.handleRequest(ViewRelatio | n.java:59) | at | org.apache.velocity.servlet.VelocityServlet.doRequest(VelocitySer | vlet.java:331) | at | org.apache.velocity.servlet.VelocityServlet.doGet(VelocityServlet | .java:292) | at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) | at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) | at | org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( ApplicationFilterChain.java:247) | at | org.apache.catalina.core.ApplicationFilterChain.doFilter(Applicat | ionFilterChain.java:193) | at | org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrap | perValve.java:243) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:566) | at | org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline | .java:472) | at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) | at | org.apache.catalina.core.StandardContextValve.invoke(StandardCont | extValve.java:201) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:566) | at | org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline | .java:472) | at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) | at | org.apache.catalina.core.StandardContext.invoke(StandardContext.j | ava:2344) | at | org.apache.catalina.core.StandardHostValve.invoke(StandardHostVal | ve.java:164) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:566) | at | org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispa | tcherValve.java:170) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:564) | at | org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportVal | ve.java:170) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:564) | at | org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:564) | at | org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline | .java:472) | at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) | at | org.apache.catalina.core.StandardEngineValve.invoke(StandardEngin | eValve.java:163) | at | org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipe | line.java:566) | at | org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline | .java:472) | at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) | at | org.apache.catalina.connector.http.HttpProcessor.process(HttpProc | essor.java:1011) | at | org.apache.catalina.connector.http.HttpProcessor.run(HttpProcesso | r.java:1106) | at java.lang.Thread.run(Thread.java:484) | | versus | | 2002-07-26 04:03:27,325 ERROR AbcServlet - Cannot display page | http://www.abclinuxu.cz:8080/clanky/ViewRelation | java.lang.Exception: Relation is null! | at | cz.abclinuxu.servlets.view.ViewRelation.handleRequest(ViewRelatio | n.java:59) | at | org.apache.velocity.servlet.VelocityServlet.doRequest(VelocitySer | vlet.java:331) | at | org.apache.velocity.servlet.VelocityServlet.doGet(VelocityServlet | .java:292) | at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) | at java.lang.Thread.run(Thread.java:484) | | if I could filter trace of org.apache package. | | | Such feature would be attractive to me, because 90% of my logs | belong to tomcat :-( | | Thanks for your ideas | | Leos | | -- | Leos Literak | http://AbcLinuxu.cz - tady je tucnakum hej! | | | | -- | To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> ************************************************************************* Copyright ERA Technology Ltd. 2002. (www.era.co.uk). All rights reserved. The information supplied in this email should be treated in confidence. No liability whatsoever is accepted for any loss or damage suffered as a result of accessing this message or any attachments. ________________________________________________________________________ This email has been scanned for all viruses by the MessageLabs SkyScan service. For more information on a proactive anti-virus service working around the clock, around the globe, visit http://www.messagelabs.com ________________________________________________________________________ -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>