Login
New User?
Register for free here.
  • Home
  • Products
  • Documentation
  • Crash Reports
Overview Getting Started Downloads
Getting Started Benefits Frequently Asked Questions Bugsplat Return On Investment   Company Information
Post a Crash Report
Latest news  RSS
BugSplat Announces Support for Windows 64-bit Applications
(December 16th, 2008)

BugSplat Adds Hang Detection to its Native Windows Application Support
(April 13th, 2008)
more...
Testimonials
 "BugSplat has become such an integral part of our engineering and QA process now, that I do not know how we survived without it for so long."
John Ulmer, Google
more...
BugSplat Statistics
1735601 reports received.
Last report received 1 minute, 14 seconds ago.
Getting Started with Sun Java J2SE 1.4 Applications

On this page, we will show you in a few simple steps how your Java application can be modified to provide full debug information on the BugSplat website when it crashes.

To get a feel for the BugSplat service prior to enabling your application, feel free to experiment with the MyJavaCrasher sample application which is part of the BugSplat software development kit that can be downloaded by registered users..

Enabling your application with BugSplat technology:

First, make sure you have completed the following checklist:

  1. Register as a new BugSplat User.
  2. Download and unzip the BugSplat software development kit for Sun Java J2SE 1.4 Applications.

Creating defect reports using your own application

Add BugSplat to your application as follows:

  • Add the following libraries to your CLASSPATH:
    • BugSplat "bugsplat.jar"
    • Apache SOAP "soap.jar"
    • Sun JavaMail "mailapi.jar"
    • Sun JavaBeans Activation "activation.jar"
  • Import the BugSplat exception handler class com.bugsplatsoftware.client.BugSplat.
  • Add a call to BugSplat.Init as shown in the sample code above for MyJavaCrasher.
  • The initialization call requires three parameters: BugSplat database, application name and version. You supply application name and version. The BugSplat database is created and selected on the Manage Versions page. Typically, you will create a new database for each major release of your product.
  • Add a try-catch block in your application entry point (for example, in main).
  • To handle both runtime Exceptions and Errors, catch Throwable, construct an Exception object, and pass it to BugSplat.HandleException.

Catching exceptions in Threads

If your application creates threads, you will want an exception report to be generated before the thread is terminated:

  • Subclass the ThreadGroup class, and override the uncaughtException method:

    class MyThreadGroup extends ThreadGroup {
      public MyThreadGroup(String s) {
        super(s);
      }
      public void uncaughtException(Thread thread, Throwable throwable) {
        BugSplat.HandleException(new Exception(throwable));
      }
    }
  • Construct an instance of your ThreadGroup class.
  • Construct an instance of your Thread, providing your ThreadGroup instance in the constructor.
  • Start the thread.

Remember to test your application by forcing a crash, and verifying that crashes are posted a good call stack is created.

Please contact us with any questions or problems you have - we want to help!

Home - Company - Post a crash report - Careers - Contact Us - Store
Use of this site is governed by our Terms & Conditions and Privacy Policy. Copyright © 2003-2009 Bugsplat Software. All rights reserved.