You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Niall Pemberton (JIRA)" <ji...@apache.org> on 2009/10/01 13:24:23 UTC
[jira] Resolved: (BEANUTILS-327) JDBCDynaClass throws class not
found exception under java6
[ https://issues.apache.org/jira/browse/BEANUTILS-327?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Niall Pemberton resolved BEANUTILS-327.
---------------------------------------
Resolution: Fixed
Fix Version/s: 1.8.1
Assignee: Niall Pemberton
My mistake, I didn't look carefully enough and see the ClassLoader still being used in the forName method.
I have committed this change:
http://svn.apache.org/viewvc?view=rev&revision=820611
> JDBCDynaClass throws class not found exception under java6
> ----------------------------------------------------------
>
> Key: BEANUTILS-327
> URL: https://issues.apache.org/jira/browse/BEANUTILS-327
> Project: Commons BeanUtils
> Issue Type: Bug
> Components: DynaBean
> Affects Versions: 1.8.0
> Environment: Windows XP
> Suse Linux
> Java6
> Reporter: Sascha Riemann
> Assignee: Niall Pemberton
> Fix For: 1.8.1
>
>
> Using ResulsetDynaClass with a byte array (e.g. varbinary) throws a class not found exception.
> Doing some research on the web, i found the following entry http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6516909,
> Patching the JDBCDynaClass was quiet easy.
> protected Class loadClass(String className) throws SQLException {
> try {
> ClassLoader cl = Thread.currentThread().getContextClassLoader();
> if (cl == null) {
> cl = this.getClass().getClassLoader();
> }
> // return (cl.loadClass(className));
> // FIX: for http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6516909
> return (Class.forName(className, false, cl));
> } catch (Exception e) {
> throw new SQLException(
> "Cannot load column class '" + className + "': " + e);
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.