[jboss-jira] [JBoss JIRA] Created: (JBREFLECT-38) ValueConvertor.convertValue is swallowing too many exceptions
Scott M Stark (JIRA)
jira-events at lists.jboss.org
Fri Sep 26 20:29:20 EDT 2008
ValueConvertor.convertValue is swallowing too many exceptions
-------------------------------------------------------------
Key: JBREFLECT-38
URL: https://jira.jboss.org/jira/browse/JBREFLECT-38
Project: JBoss Reflection
Issue Type: Bug
Reporter: Scott M Stark
ValueConvertor.convertValue(Class<Object>, Object, boolean, boolean) is swallowing too many exceptions. A bean like:
<bean name="JndiBindings" class="org.jboss.naming.BindingsInitializer">
<property name="ctx">
<inject bean="InitialContextFactory" property="ctx"/>
</property>
<property name="bindings">
<map keyClass="java.lang.String">
<entry>
<key>ints/1</key>
<value class="java.lang.Integer">1</value>
</entry>
<entry>
<key>strings/1</key>
<value class="java.lang.String">String1</value>
</entry>
<entry>
<key>bigint/1</key>
<value class="java.math.BigInteger">12345.6789</value>
</entry>
</map>
</property>
</bean>
Incorrectly creates a String value for the bigint/1 entry because the attempt to call BigInteger("12345.6789") fails with
an java.lang.reflect.InvocationTargetException/java.lang.NumberFormatException: For input string: "2345.6789"
in ReflectionUtils.newInstance(Constructor<?>, Object[]) line: 153
We need to look at differentiating between failures.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list