[ 
https://issues.apache.org/struts/browse/WW-2035?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

James Holmes updated WW-2035:
-----------------------------

    Issue Type: Improvement  (was: Bug)

> ConfigurationManager overwrites exception stacktraces
> -----------------------------------------------------
>
>                 Key: WW-2035
>                 URL: https://issues.apache.org/struts/browse/WW-2035
>             Project: Struts 2
>          Issue Type: Improvement
>          Components: Configuration
>    Affects Versions: 2.0.8
>            Reporter: Jake Robb
>            Assignee: James Holmes
>            Priority: Minor
>             Fix For: 2.1.0
>
>
> Line 51-56 of ConfigurationManager.java:
> try {
>     configuration.reload(getConfigurationProviders());
> } catch (ConfigurationException e) {
>     setConfiguration(null);
>     throw e;
> }
> Note that the caught exception is re-thrown, overwriting the stacktrace.  
> This should be replaced with:
> throw new WhateverException("something went wrong here", e);
> Replacing, of course, the exception type and message with something more 
> indicative of the problem.
> To see the real exception and its message, I had to download the Struts 
> source, link it in to my project, and debug my way to the exception.  It was 
> annoying, to say the least.
> In my case, the problem was that my build scripts were including the Struts 
> JARs in my APP-INF/lib directory, and as such the xwork JAR was being loaded 
> twice.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to