Setting up an example error trapping page
For every application technology and/or web server an example error page can be set up to help other users of the same technology.
If you contribute an error trapping example page for a technology and it gets accepted and published on BugsVoice site, you get a full year of free usage. You must release your page example under MIT license or wider.
Assuming you are enrolled and familiar to BugsVoice basic error page serving and feedback collecting, which works for all technologies and web servers J, in order to provide a more complete example for your favorite technology we suggest you to first of all take a look at the errorJava.jsp page which you can download from the rule editor in BugsVoice.
Your example page should:
- Give help on how to centralize errors
- Supply examples on how to get the values you want to submit to BugsVoice
1. Give help on how to centralize errors
The provided example for Java gives these hints, in a commented out initial part:
Before you get errors in your BugsVoice account, you must trap all the errors of your application. To introduce a global error handler, you can modify your application
web.xml adding these lines:
<web-app>
<!– ….. –>
<error-page>
<error-code>404</error-code>
<location>/error.jsp</location>
</error-page><error-page>
<exception-type>java.lang.Throwable</exception-type>
<location>/error.jsp</location>
</error-page>
<!– ….. –>
</web-app>
This done, you can use this JSP as “error,jsp”.
This is the standard way errors are trapped in Java; of course advanced developers can customize this behavior.
You should provide something similar, the “default” way of centralizing errors for your technology.
2. Supply examples on how to get the values you want to submit to BugsVoice
The provided example for Java computes the server date this way:
//get server time
SimpleDateFormat sdf = new SimpleDateFormat(“yyyy MM dd HH:mm:ss”);
String serverTime = sdf.format(new Date());
Which is then used in feeding the form submitted to BugsVoice this way:
<textarea name=”serverDate”><%=serverTime%></textarea>
On your page you should proceed in a similar vein; the set of properties which you can send is listed on the “configure error trapping” page, at the bottom.
Thanks for contributing!





[...] server status, database status, memory etc.) and redirects the user to our BugsVoice server (see how to configure an error trapping page on BugsVoice blog for more [...]
Solving the "halting problem"…. « Eltit Golb
November 18, 2009 at 9:24 am
[...] also How to contribute a sample error trapping page for your favorite technology. Categories: Web applications Tags: error trapping Comments (0) Trackbacks (0) Leave a [...]
BugsVoice online service – public beta is here! « Open Lab's blog
November 18, 2009 at 9:38 am
[...] see also: setting up an example error trapping page [...]
BugsVoice (beta) is out!! « Matteo Bicocchi’s Blog
November 18, 2009 at 7:06 pm