tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kiran Badi <>
Subject Logging framework for Tomcat -Exceptions
Date Thu, 12 Jul 2012 01:05:25 GMT

I have below code for catching DAO exceptions,but I feel its not correct 
way to do this,Can some one point me to some library which will capture 
all exceptions which my code will throw and works with tomcat. I 
implementing Model2 mvc pattern and to my surprise I am able to show 
values to the view but database is not getting inserted.I am lost given 
that no exception is also being thrown anywhere.All logs looks clean but 
DB is not updated.

import java.sql.Connection;

public interface DAO {

     Connection getConnection() throws DAOException;


public class DAOException extends Exception {
     private static final long serialVersionUID = 19192L;

     public DAOException() {
     public DAOException(String message) {
         this.message = message;
     public String getMessage() {
         return message;
     public void setMessage(String message) {
         this.message = message;
     private String message;

     public String toString() {
         return message;

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message