New exception handling

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

New exception handling

Gerd Wagner
Hi,

till today SQuirreL developers had to take care themselves that
exceptions were properly logged. As a result many exception went up to
Swing's event queue which just printed the stacktrace to standard out.

Now SQuirreL has its own event queue (see Application.startup) which
properly logs exceptions. This allows developers to just throw on
exceptions if they don't want to handle them in their own code. It is
even alright if the developers wrap a declared exception into a
RuntimeException as in the following example:

catch(SQLException e)
{
    throw new RuntimeException(e);
}

In case your code is not running in the event queue thread but in your
own thread, logging will be properly done if you use SQuirreL's
TaskThreadPool.

The new Log panel in SQuirreL's status bar makes it easy to observe
logs. See description in change log,
http://cvs.sourceforge.net/viewcvs.py/squirrel-sql/sql12/doc/changes.txt?view=markup

Gerd


-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
Squirrel-sql-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/squirrel-sql-develop
Loading...