DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=31052>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31052

org.apache.naming.factory.BeanFactory does not propage root exceptions

           Summary: org.apache.naming.factory.BeanFactory does not propage
                    root exceptions
           Product: Tomcat 5
           Version: 5.0.0
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Catalina:Modules
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


Only the error messages are propagated in the NamingException:

            } catch (java.beans.IntrospectionException ie) {
                throw new NamingException(ie.getMessage());
            }

Since some exceptions do not have a message associated with it, it is very hard 
sometimes to tell what went wrong from the NamingException. So it would be nice 
if the actual exception was chained with the NamingException. The change is 
small:

            } catch (java.lang.IllegalAccessException iae) {
                NamingException ex = new new NamingException(iae.getMessage());
                ex.setRootCause(iae);
                throw ex;
            }

Also, there is a call to e.printStackTrace() which probably shouldn't be there.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to