We'd need rev 1063823 and 1063867. On the surface it looks like code cleanup
- is there a concrete bug here that needs fixing?

-mike

On Thu, Jan 27, 2011 at 9:27 AM, Albert Lee <[email protected]> wrote:

> Should this go back to 2.1.x since the exception is wrapped with
> ParseException and a new messages are added?
>
> Thanks,
> Albert Lee.
>
> On Wed, Jan 26, 2011 at 2:50 PM, <[email protected]> wrote:
>
> > Author: ppoddar
> > Date: Wed Jan 26 20:50:23 2011
> > New Revision: 1063867
> >
> > URL: http://svn.apache.org/viewvc?rev=1063867&view=rev
> > Log:
> > Add exception message for configuration error
> >
> > Modified:
> >
> >
>  
> openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Options.java
> >
> > Modified:
> >
> openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Options.java
> > URL:
> >
> http://svn.apache.org/viewvc/openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Options.java?rev=1063867&r1=1063866&r2=1063867&view=diff
> >
> >
> ==============================================================================
> > ---
> >
> openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Options.java
> > (original)
> > +++
> >
> openjpa/trunk/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Options.java
> > Wed Jan 26 20:50:23 2011
> > @@ -33,7 +33,6 @@ import java.util.Properties;
> >  import java.util.TreeSet;
> >
> >  import org.apache.commons.lang.StringUtils;
> > -import org.apache.openjpa.util.UserException;
> >
> >  import serp.util.Strings;
> >
> > @@ -440,7 +439,7 @@ public class Options extends TypedProper
> >                 str = "true";
> >             return cons.newInstance(new Object[]{ str });
> >         } catch (Exception e) {
> > -            err = new UserException(_loc.get("conf-no-constructor", str,
> > type), e);
> > +            err = new ParseException(_loc.get("conf-no-constructor",
> str,
> > type), e);
> >         }
> >
> >         // special case: the argument value is a subtype name and a new
> > instance
> > @@ -450,13 +449,12 @@ public class Options extends TypedProper
> >             subType = Class.forName(str);
> >         } catch (Exception e) {
> >             err = e;
> > -            throw new UserException(_loc.get("conf-no-type", str, type),
> > e);
> > +            throw new ParseException(_loc.get("conf-no-type", str,
> type),
> > e);
> >         }
> >         if (!type.isAssignableFrom(subType))
> >             throw err;
> >         try {
> > -            return AccessController.doPrivileged(
> > -                J2DoPrivHelper.newInstanceAction(subType));
> > +            return
> > AccessController.doPrivileged(J2DoPrivHelper.newInstanceAction(subType));
> >         } catch (PrivilegedActionException pae) {
> >             throw pae.getException();
> >         }
> >
> >
> >
>
>
> --
> Albert Lee.
>

Reply via email to