JBoss Community

Re: Class loader issues

created by Holger L in Snowdrop - View the full discussion

Hello,

 

Does the snowdrop module also look at the EAR lib directory of an application and includes its classpath? I've got an EAR app which uses the old fashion Hibernate3 (org.springframework.orm.hibernate3.LocalSessionFactoryBean). The deployment fails on a ClassNotFoundException:

 

Caused by: java.lang.NoClassDefFoundError

          at org.springframework.orm.hibernate3.LocalSessionFactoryBean.class$(LocalSessionFactoryBean.java:174)

          at org.springframework.orm.hibernate3.LocalSessionFactoryBean.<init>(LocalSessionFactoryBean.java:174)

          at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.6.0_31]

          at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) [rt.jar:1.6.0_31]

          at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) [rt.jar:1.6.0_31]

          at java.lang.reflect.Constructor.newInstance(Constructor.java:513) [rt.jar:1.6.0_31]

          at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:100)

          ... 24 more

Caused by: java.lang.ClassNotFoundException: org.hibernate.cfg.Configuration from [Module "org.springframework.spring:snowdrop" from local module loader @7f56b6b9]

          at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)

          at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)

 

The EAR/lib dire contains the hibernate-core (which contains org.hibernate.cfg.Configuration) and I've added the org.hibernate exclusion to the deployment structure.

 

Any help would be appreciated.

 

Thanks

Reply to this message by going to Community

Start a new discussion in Snowdrop at Community