You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by SiSi'mon <s_...@purpleblade.net> on 2007/05/23 18:42:26 UTC

web.xml error-page

I am having extremely severe problems with MyFaces right now.  The biggest
problem is that when MyFaces breaks (throws an exception), you never know
about it sometimes.  There is no information in the log files etc.

What I would like to do is to somehow print out a stack trace in the browser
window if tomcat encounters any kind of exception thrown by
"org.apache.myfaces.*"  but I do not know how to use wildcards in the
web.xml file for error pages.

It seems like the error-page tag needs a fully qualified exception class and
the following will not work.
any ideas?

    <error-page>
        <exception-type>org.apache.myfaces.*</exception-type>
        <location>/web/error/Faces.jsf</location>
    </error-page>
-- 
View this message in context: http://www.nabble.com/web.xml-error-page-tf3805201.html#a10767952
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: web.xml error-page

Posted by SiSi'mon <s_...@purpleblade.net>.
Even with h:messages, commons logging, there are some exceptions being thrown
that no one ever sees, especially in myfaces.  A page will not render and
there will absolutely no info in the log4j log files.

thanks for your help

Si'mon



David Delbecq-2 wrote:
> 
> If you need to catch a wide range of Exceptions in an error page, i
> suggest you use a generic error page. The error page has access to the
> Exception Object and can then include other JSP that show specific errors.
> 
> As for informations in logs file, Exceptions thrown during process of
> JSF outputed using common-logging. Most people i think configure
> common-logging to output using log4j, which itself is easy to configure.
> to get up to debug level, filter on classes, have Some specific error
> messages sent by email, etc.
> 
> Last but not least, a common beginner mistake with JSF is to forget to
> use <h:message/> in pages, which display effective components errors
> occured during last request.
> 
> 
> SiSi'mon a écrit :
>> I am having extremely severe problems with MyFaces right now.  The
>> biggest
>> problem is that when MyFaces breaks (throws an exception), you never know
>> about it sometimes.  There is no information in the log files etc.
>>
>> What I would like to do is to somehow print out a stack trace in the
>> browser
>> window if tomcat encounters any kind of exception thrown by
>> "org.apache.myfaces.*"  but I do not know how to use wildcards in the
>> web.xml file for error pages.
>>
>> It seems like the error-page tag needs a fully qualified exception class
>> and
>> the following will not work.
>> any ideas?
>>
>>     <error-page>
>>         <exception-type>org.apache.myfaces.*</exception-type>
>>         <location>/web/error/Faces.jsf</location>
>>     </error-page>
>>   
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/web.xml-error-page-tf3805201.html#a10771688
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: web.xml error-page

Posted by SiSi'mon <s_...@purpleblade.net>.
thanks, we are using all of these including <h:message.  Error messages in
pages using JSF but many of the MyFaces exceptions are never brought to
light.  they stay buried.

Do you have more information on this global exception that gets added to
when any exception anywhere is thrown.

we are using commons-logging but no one every looks at the files and
customers are unlikely to go look at the files on ocassion and send us the
info.

The idea is to have erery exception thrown bubble up to the web app screen. 
This has been proven hard to do.

---

David Delbecq-2 wrote:
> 
> If you need to catch a wide range of Exceptions in an error page, i
> suggest you use a generic error page. The error page has access to the
> Exception Object and can then include other JSP that show specific errors.
> 
> As for informations in logs file, Exceptions thrown during process of
> JSF outputed using common-logging. Most people i think configure
> common-logging to output using log4j, which itself is easy to configure.
> to get up to debug level, filter on classes, have Some specific error
> messages sent by email, etc.
> 
> Last but not least, a common beginner mistake with JSF is to forget to
> use <h:message/> in pages, which display effective components errors
> occured during last request.
> 
> 
> SiSi'mon a écrit :
>> I am having extremely severe problems with MyFaces right now.  The
>> biggest
>> problem is that when MyFaces breaks (throws an exception), you never know
>> about it sometimes.  There is no information in the log files etc.
>>
>> What I would like to do is to somehow print out a stack trace in the
>> browser
>> window if tomcat encounters any kind of exception thrown by
>> "org.apache.myfaces.*"  but I do not know how to use wildcards in the
>> web.xml file for error pages.
>>
>> It seems like the error-page tag needs a fully qualified exception class
>> and
>> the following will not work.
>> any ideas?
>>
>>     <error-page>
>>         <exception-type>org.apache.myfaces.*</exception-type>
>>         <location>/web/error/Faces.jsf</location>
>>     </error-page>
>>   
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/web.xml-error-page-tf3805201.html#a10771652
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: web.xml error-page

Posted by David Delbecq <de...@oma.be>.
If you need to catch a wide range of Exceptions in an error page, i
suggest you use a generic error page. The error page has access to the
Exception Object and can then include other JSP that show specific errors.

As for informations in logs file, Exceptions thrown during process of
JSF outputed using common-logging. Most people i think configure
common-logging to output using log4j, which itself is easy to configure.
to get up to debug level, filter on classes, have Some specific error
messages sent by email, etc.

Last but not least, a common beginner mistake with JSF is to forget to
use <h:message/> in pages, which display effective components errors
occured during last request.


SiSi'mon a écrit :
> I am having extremely severe problems with MyFaces right now.  The biggest
> problem is that when MyFaces breaks (throws an exception), you never know
> about it sometimes.  There is no information in the log files etc.
>
> What I would like to do is to somehow print out a stack trace in the browser
> window if tomcat encounters any kind of exception thrown by
> "org.apache.myfaces.*"  but I do not know how to use wildcards in the
> web.xml file for error pages.
>
> It seems like the error-page tag needs a fully qualified exception class and
> the following will not work.
> any ideas?
>
>     <error-page>
>         <exception-type>org.apache.myfaces.*</exception-type>
>         <location>/web/error/Faces.jsf</location>
>     </error-page>
>   


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org