[hibernate-issues] [Hibernate-JIRA] Updated: (HHH-5329) NoClassDefFoundError when using Hibernate 3.5 with J2SE 1.4 because of a wrong catch block
Steve Ebersole (JIRA)
noreply at atlassian.com
Tue Jun 22 14:10:09 EDT 2010
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-5329?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steve Ebersole updated HHH-5329:
--------------------------------
Assignee: Emmanuel Bernard
Affects Version/s: (was: 3.5.3)
(was: 3.5.2)
(was: 3.5.1)
Fix Version/s: 3.5.x
I did not list 3.6 (trunk) because it requires JDK 1.5 minimum, but we should change that code on trunk if it is doing the reflection calls. I'll create a follow up for that
> NoClassDefFoundError when using Hibernate 3.5 with J2SE 1.4 because of a wrong catch block
> ------------------------------------------------------------------------------------------
>
> Key: HHH-5329
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5329
> Project: Hibernate Core
> Issue Type: Bug
> Components: core
> Affects Versions: 3.5.0-Final
> Environment: Hibernate 3.5, Java SE 1.4 or J2EE 1.3
> Reporter: Francesco Poli
> Assignee: Emmanuel Bernard
> Priority: Blocker
> Fix For: 3.5.x
>
>
> In org.hibernate.impl.SessionFactoryImpl is done this check when looking for concurrent classes during the creation of the SessionFactory:
> Statistics concurrentStatistics = null;
> try {
> Class concurrentStatsClass = ReflectHelper.classForName("org.hibernate.stat.ConcurrentStatisticsImpl");
> Constructor constructor = concurrentStatsClass.getConstructor(new Class[]{SessionFactoryImplementor.class});
> concurrentStatistics = (Statistics) constructor.newInstance(new Object[]{this});
> log.trace("JDK 1.5 concurrent classes present");
> } catch (Exception noJava5) {
> log.trace("JDK 1.5 concurrent classes missing");
> }
> But what is thrown is a NoClassDefFoundError, which is not an Exception.
> As a consequence, the catch block won't work and the error is propagated to the upper levels of the application.
> I suggest to modify the catch arguments to match the correct type of the thrown object.
> Thank you.
> Bye
> Francesco Poli
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list