RE: Error 500 with stack trace
Mattias Jiderhamn <[email protected]> Wed, 03 May 2006 09:53:41 +0200
| Newsgroups | gmane.text.xml.resin.user |
|---|---|
| Message-ID | <[email protected]> |
This has caused us some trouble, since we have the error logging in an "error servlet". Even if the error message cannot be shown in the browser, we want the error to be logged. At 2006-05-03 08:02, you wrote: >Hi, > >I've noticed that there's a difference on how >Resin 3 handles errorpage-things compared to >Resin 2. It seems that if there is an error in >your JSP after something is already written to >the response and its buffer has been committed, >the errorpage cannot be shown anymore via the >forward mechanism. This is propably what the >spec expects, but Resin 2 didn't work like this... > >-Kai > > >---------- >From: [email protected] >[mailto:[email protected]] On Behalf Of Gary Wells >Sent: 2. toukokuuta 2006 21:33 >To: [email protected] >Subject: RE: Error 500 with stack trace > >To clarify my two questions further > > > >1) How do you get the custom error 500 page to >display? Ive got the following in my web.xml: > > > ><error-page> > > <error-code>500</error-code> > > <location>/500.jsp</location> > > </error-page> > > > > but when an 500 error is thrown I get the following error message: > > > >java.lang.IllegalStateException: forward() not allowed after buffer has > >committed. > >at >com.caucho.server.webapp.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:139) > >at >com.caucho.server.webapp.RequestDispatcherImpl.error(RequestDispatcherImpl.java:113) > >at >com.caucho.server.webapp.ErrorPageManager.sendServletError(ErrorPageManager.java:363) > >at >com.caucho.server.webapp.WebAppFilterChain.doFilter(WebAppFilterChain.java:180) > >at >com.caucho.server.dispatch.ServletInvocation.service(ServletInvocation.java:229) > >at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:268) > >at com.caucho.server.port.TcpConnection.run(TcpConnection.java:389) > >at com.caucho.util.ThreadPool.runTasks(ThreadPool.java:492) > >at com.caucho.util.ThreadPool.run(ThreadPool.java:425) > >at java.lang.Thread.run(Thread.java:613) > > > > > >2) How do you gain access to the stack trace of >the original exception so it can be displayed? > > > > > >Thanks G > > > >---------- >From: Gary Wells [mailto:[email protected]] >Sent: Tuesday, May 02, 2006 10:51 AM >To: '[email protected]' >Subject: Error 500 with stack trace > > > >Does anybody know how to setup Resin with a >custom page for an error 500 that displays the stack trace? > > > >Thanks G