-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 
Author Message
 Post subject: Hibernate+Struts integration problem
PostPosted: Wed Aug 01, 2007 4:42 am 
Newbie

Joined: Mon Jul 30, 2007 1:22 pm
Posts: 5
Hello there!

I'm developing a webapp and I need to integrate Hibernate and Struts. I used the HibernatePlugin found in the Hibernate website, the struts config is ok (I've added the plugin configuration as mentioned in the website...). The hibernate.cfg.xml file is also ok. The problem is that when I try to load the webapp I get the log messages below.
I have all the jar files in place, in the lib folders of the webapp and of the appserver (Tomcat5).

What is the problem?? What can I do to solve it??

Thanks in advance,

Paulo Ferreira


=========== Tomcat Log ============

SEVERE: Exception while initializing Hibernate.
30-Jul-07 6:25:13 PM srsleiria.aprov.rolDB.HibernatePlugIn initHibernate
SEVERE: Rethrowing exception...
java.lang.NoClassDefFoundError: net.sf.cglib.proxy.Enhancer
at java.lang.Class.initializeClass(libgcj.so.7rh)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.getProxyFactory(CGLIBLazyInitializer.java:117)
at org.hibernate.proxy.pojo.cglib.CGLIBProxyFactory.postInstantiate(CGLIBProxyFactory.java:43)
at org.hibernate.tuple.entity.PojoEntityTuplizer.buildProxyFactory(PojoEntityTuplizer.java:162)
at org.hibernate.tuple.entity.AbstractEntityTuplizer.<init>(AbstractEntityTuplizer.java:135)
at org.hibernate.tuple.entity.PojoEntityTuplizer.<init>(PojoEntityTuplizer.java:55)
at org.hibernate.tuple.entity.EntityEntityModeToTuplizerMapping.<init>(EntityEntityModeToTuplizerMapping.java:56)
at org.hibernate.tuple.entity.EntityMetamodel.<init>(EntityMetamodel.java:295)
at org.hibernate.persister.entity.AbstractEntityPersister.<init>(AbstractEntityPersister.java:434)
at org.hibernate.persister.entity.SingleTableEntityPersister.<init>(SingleTableEntityPersister.java:109)
at org.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:55)
at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:226)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1294)
at srsleiria.aprov.rolDB.HibernatePlugIn.initHibernate(HibernatePlugIn.java:128)
at srsleiria.aprov.rolDB.HibernatePlugIn.init(HibernatePlugIn.java:105)
at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:869)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:336)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployWAR(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.check(catalina-5.5.17.jar.sonsfe88.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.commons.modeler.BaseModelMBean.invoke(jakarta-commons-modeler-1.1.jar.so)
at mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.MX4JMBeanServer.invoke(mx4j-3.0.1.jar.so)
at org.apache.catalina.manager.ManagerServlet.check(catalina-manager-5.5.17.jar.so)
at org.apache.catalina.manager.HTMLManagerServlet.doPost(catalina-manager-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapperValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContextValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHostValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.valves.ErrorReportValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardEngineValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.connector.CoyoteAdapter.service(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.coyote.http11.Http11Processor.process(tomcat-http-5.5.17.jar.so)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(tomcat-http-5.5.17.jar.so)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(tomcat-util-5.5.17.jar.so)
at java.lang.Thread.run(libgcj.so.7rh)
Caused by: java.lang.ClassNotFoundException: org.objectweb.asm.Type
at org.apache.catalina.loader.WebappClassLoader.loadClass(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.loader.WebappClassLoader.loadClass(catalina-5.5.17.jar.sonsfe88.so)
at java.lang.Class.initializeClass(libgcj.so.7rh)
...55 more
30-Jul-07 6:25:13 PM org.apache.struts.action.ActionServlet init
SEVERE: Unable to initialize Struts ActionServlet due to an unexpected exception or error thrown, so marking the servlet as unavailable. Most likely, this is due to an incorrect or missing library dependency.
javax.servlet.ServletException: net.sf.cglib.proxy.Enhancer
at srsleiria.aprov.rolDB.HibernatePlugIn.initHibernate(HibernatePlugIn.java:140)
at srsleiria.aprov.rolDB.HibernatePlugIn.init(HibernatePlugIn.java:105)
at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:869)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:336)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployWAR(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.check(catalina-5.5.17.jar.sonsfe88.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.commons.modeler.BaseModelMBean.invoke(jakarta-commons-modeler-1.1.jar.so)
at mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.MX4JMBeanServer.invoke(mx4j-3.0.1.jar.so)
at org.apache.catalina.manager.ManagerServlet.check(catalina-manager-5.5.17.jar.so)
at org.apache.catalina.manager.HTMLManagerServlet.doPost(catalina-manager-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapperValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContextValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHostValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.valves.ErrorReportValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardEngineValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.connector.CoyoteAdapter.service(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.coyote.http11.Http11Processor.process(tomcat-http-5.5.17.jar.so)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(tomcat-http-5.5.17.jar.so)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(tomcat-util-5.5.17.jar.so)
at java.lang.Thread.run(libgcj.so.7rh)
30-Jul-07 6:25:13 PM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet action as unavailable
30-Jul-07 6:25:13 PM org.apache.catalina.core.StandardContext loadOnStartup
SEVERE: Servlet /Rol threw load() exception
javax.servlet.UnavailableException: net.sf.cglib.proxy.Enhancer
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:368)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployWAR(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.startup.HostConfig.check(catalina-5.5.17.jar.sonsfe88.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.commons.modeler.BaseModelMBean.invoke(jakarta-commons-modeler-1.1.jar.so)
at mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke(mx4j-3.0.1.jar.so)
at mx4j.server.MX4JMBeanServer.invoke(mx4j-3.0.1.jar.so)
at org.apache.catalina.manager.ManagerServlet.check(catalina-manager-5.5.17.jar.so)
at org.apache.catalina.manager.HTMLManagerServlet.doPost(catalina-manager-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at javax.servlet.http.HttpServlet.service(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardWrapperValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardContextValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardHostValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.valves.ErrorReportValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.core.StandardEngineValve.invoke(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.catalina.connector.CoyoteAdapter.service(catalina-5.5.17.jar.sonsfe88.so)
at org.apache.coyote.http11.Http11Processor.process(tomcat-http-5.5.17.jar.so)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(tomcat-http-5.5.17.jar.so)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(tomcat-util-5.5.17.jar.so)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(tomcat-util-5.5.17.jar.so)
at java.lang.Thread.run(libgcj.so.7rh)
30-Jul-07 6:25:33 PM org.hibernate.connection.DriverManagerConnectionProvider close
INFO: cleaning up connection pool: jdbc:mysql://localhost:3306/rol
30-Jul-07 6:25:42 PM org.apache.catalina.core.StandardWrapperValve invoke
INFO: Servlet action is currently unavailable


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 01, 2007 5:08 am 
Expert
Expert

Joined: Tue Dec 07, 2004 6:57 am
Posts: 285
Location: Nürnberg, Germany
cglib.jar is missing in your classpath

_________________
Please don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 01, 2007 5:36 am 
Newbie

Joined: Mon Jul 30, 2007 1:22 pm
Posts: 5
But I have cglib.jar in WEB-INF/lib and in the lib folder of Tomcat5!!

Where should I have it so that it works?

Paulo Ferreira


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 01, 2007 7:35 am 
Newbie

Joined: Mon Jul 30, 2007 1:22 pm
Posts: 5
Navigating the Hibernate website, I found another solution to integrate Hibernate & Struts; the solution is to use a Filter, and the code to do that is in the Hibernate website.

Which way is best? To use the plugin or the Filter?? I haven't yet tried the Filter solution, because I just want to know if it's worth trying it...

Thank you very much,

Paulo


Top
 Profile  
 
 Post subject:
PostPosted: Fri Aug 03, 2007 4:51 am 
Newbie

Joined: Mon Jul 30, 2007 1:22 pm
Posts: 5
The previous error is now solved, but now there is a new one:

3-Aug-07 9:50:11 AM org.hibernate.cfg.Environment <clinit>
INFO: Hibernate 3.2.4.sp1
3-Aug-07 9:50:11 AM org.hibernate.cfg.Environment <clinit>
INFO: hibernate.properties not found
3-Aug-07 9:50:11 AM org.hibernate.cfg.Environment buildBytecodeProvider
INFO: Bytecode provider name : cglib
3-Aug-07 9:50:11 AM org.hibernate.cfg.Environment <clinit>
INFO: using JDK 1.4 java.sql.Timestamp handling
3-Aug-07 9:50:11 AM org.hibernate.cfg.Configuration configure
INFO: configuring from url: file:/var/lib/tomcat5/webapps/Rol/WEB-INF/classes/hibernate.cfg.xml
3-Aug-07 9:50:11 AM org.hibernate.cfg.Configuration addResource
INFO: Reading mappings from resource : srsleiria/aprov/rol/Unidade.hbm.xml
3-Aug-07 9:50:11 AM org.hibernate.cfg.HbmBinder bindRootPersistentClassCommonValues
INFO: Mapping class: srsleiria.aprov.rol.Unidade -> unidades
3-Aug-07 9:50:12 AM org.hibernate.cfg.Configuration doConfigure
INFO: Configured SessionFactory: rol:/hibernate/SessionFactory
3-Aug-07 9:50:12 AM org.hibernate.connection.DriverManagerConnectionProvider configure
INFO: Using Hibernate built-in connection pool (not for production use!)
3-Aug-07 9:50:12 AM org.hibernate.connection.DriverManagerConnectionProvider configure
INFO: Hibernate connection pool size: 20
3-Aug-07 9:50:12 AM org.hibernate.connection.DriverManagerConnectionProvider configure
INFO: autocommit mode: false
3-Aug-07 9:50:12 AM org.hibernate.connection.DriverManagerConnectionProvider configure
INFO: using driver: com.mysql.jdbc.Driver at URL: jdbc:mysql://localhost:3306/rol
3-Aug-07 9:50:12 AM org.hibernate.connection.DriverManagerConnectionProvider configure
INFO: connection properties: {user=roluser, password=****}
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: RDBMS: MySQL, version: 5.0.22
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: JDBC driver: MySQL-AB JDBC Driver, version: mysql-connector-java-5.0.4 ( $Date: 2006-10-19 17:47:48 +0200 (Thu, 19 Oct 2006) $, $Revision: 5908 $ )
3-Aug-07 9:50:12 AM org.hibernate.dialect.Dialect <init>
INFO: Using dialect: org.hibernate.dialect.MySQLDialect
3-Aug-07 9:50:12 AM org.hibernate.transaction.TransactionFactoryFactory buildTransactionFactory
INFO: Transaction strategy: org.hibernate.transaction.JDBCTransactionFactory
3-Aug-07 9:50:12 AM org.hibernate.transaction.TransactionManagerLookupFactory getTransactionManagerLookup
INFO: No TransactionManagerLookup configured (in JTA environment, use of read-write or transactional second-level cache is not recommended)
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Automatic flush during beforeCompletion(): disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Automatic session close at end of transaction: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: JDBC batch size: 15
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: JDBC batch updates for versioned data: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Scrollable result sets: enabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: JDBC3 getGeneratedKeys(): enabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Connection release mode: auto
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Maximum outer join fetch depth: 2
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Default batch fetch size: 1
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Generate SQL with comments: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Order SQL updates by primary key: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Order SQL inserts for batching: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory createQueryTranslatorFactory
INFO: Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory
3-Aug-07 9:50:12 AM org.hibernate.hql.ast.ASTQueryTranslatorFactory <init>
INFO: Using ASTQueryTranslatorFactory
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Query language substitutions: {}
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: JPA-QL strict compliance: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Second-level cache: enabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Query cache: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory createCacheProvider
INFO: Cache provider: org.hibernate.cache.NoCacheProvider
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Optimize cache for minimal puts: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Structured second-level cache entries: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Statistics: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Deleted entity synthetic identifier rollback: disabled
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Default entity-mode: pojo
3-Aug-07 9:50:12 AM org.hibernate.cfg.SettingsFactory buildSettings
INFO: Named query checking : enabled
3-Aug-07 9:50:12 AM org.hibernate.impl.SessionFactoryImpl <init>
INFO: building session factory
3-Aug-07 9:50:13 AM srsleiria.aprov.rolDB.HibernatePlugIn initHibernate
SEVERE: Exception while initializing Hibernate.
3-Aug-07 9:50:13 AM srsleiria.aprov.rolDB.HibernatePlugIn initHibernate
SEVERE: Rethrowing exception...
java.lang.NoClassDefFoundError: net.sf.cglib.core.DebuggingClassWriter$1
at java.lang.Class.initializeClass(libgcj.so.7rh)
at net.sf.cglib.core.DebuggingClassWriter.toByteArray(DebuggingClassWriter.java:73)
at net.sf.cglib.core.DefaultGeneratorStrategy.generate(DefaultGeneratorStrategy.java:26)
at net.sf.cglib.core.AbstractClassGenerator.create(AbstractClassGenerator.java:216)
at net.sf.cglib.core.KeyFactory$Generator.create(KeyFactory.java:145)
at net.sf.cglib.core.KeyFactory.create(KeyFactory.java:117)
at net.sf.cglib.core.KeyFactory.create(KeyFactory.java:108)
at net.sf.cglib.core.KeyFactory.create(KeyFactory.java:104)
at net.sf.cglib.proxy.Enhancer.<clinit>(Enhancer.java:69)
at java.lang.Class.initializeClass(libgcj.so.7rh)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.getProxyFactory(CGLIBLazyInitializer.java:117)
at org.hibernate.proxy.pojo.cglib.CGLIBProxyFactory.postInstantiate(CGLIBProxyFactory.java:43)
at org.hibernate.tuple.entity.PojoEntityTuplizer.buildProxyFactory(PojoEntityTuplizer.java:162)
at org.hibernate.tuple.entity.AbstractEntityTuplizer.<init>(AbstractEntityTuplizer.java:135)
at org.hibernate.tuple.entity.PojoEntityTuplizer.<init>(PojoEntityTuplizer.java:55)
at org.hibernate.tuple.entity.EntityEntityModeToTuplizerMapping.<init>(EntityEntityModeToTuplizerMapping.java:56)
at org.hibernate.tuple.entity.EntityMetamodel.<init>(EntityMetamodel.java:295)
at org.hibernate.persister.entity.AbstractEntityPersister.<init>(AbstractEntityPersister.java:434)
at org.hibernate.persister.entity.SingleTableEntityPersister.<init>(SingleTableEntityPersister.java:109)
at org.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:55)
at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:226)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1294)
at srsleiria.aprov.rolDB.HibernatePlugIn.initHibernate(HibernatePlugIn.java:128)
at srsleiria.aprov.rolDB.HibernatePlugIn.init(HibernatePlugIn.java:105)
at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:869)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:336)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptor(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptors(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardEngine.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardService.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardServer.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.Catalina.start(catalina-5.5.17.jar.sodxk1ag.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.catalina.startup.Bootstrap.start(bootstrap.jar.so)
at org.apache.catalina.startup.Bootstrap.main(bootstrap.jar.so)
Caused by: java.lang.ClassNotFoundException: org.objectweb.asm.util.TraceClassVisitor
at org.apache.catalina.loader.WebappClassLoader.loadClass(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.loader.WebappClassLoader.loadClass(catalina-5.5.17.jar.sodxk1ag.so)
at java.lang.Class.forName(libgcj.so.7rh)
at java.lang.Class.initializeClass(libgcj.so.7rh)
...49 more
3-Aug-07 9:50:13 AM org.apache.struts.action.ActionServlet init
SEVERE: Unable to initialize Struts ActionServlet due to an unexpected exception or error thrown, so marking the servlet as unavailable. Most likely, this is due to an incorrect or missing library dependency.
javax.servlet.ServletException: net.sf.cglib.core.DebuggingClassWriter$1
at srsleiria.aprov.rolDB.HibernatePlugIn.initHibernate(HibernatePlugIn.java:140)
at srsleiria.aprov.rolDB.HibernatePlugIn.init(HibernatePlugIn.java:105)
at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:869)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:336)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptor(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptors(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardEngine.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardService.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardServer.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.Catalina.start(catalina-5.5.17.jar.sodxk1ag.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.catalina.startup.Bootstrap.start(bootstrap.jar.so)
at org.apache.catalina.startup.Bootstrap.main(bootstrap.jar.so)
3-Aug-07 9:50:13 AM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet action as unavailable
3-Aug-07 9:50:13 AM org.apache.catalina.core.StandardContext loadOnStartup
SEVERE: Servlet /Rol threw load() exception
javax.servlet.UnavailableException: net.sf.cglib.core.DebuggingClassWriter$1
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:368)
at javax.servlet.GenericServlet.init(tomcat5-servlet-2.4-api-5.5.17.jar.so)
at org.apache.catalina.core.StandardWrapper.loadServlet(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardWrapper.load(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.loadOnStartup(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardContext.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChildInternal(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.addChild(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptor(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployDescriptors(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.deployApps(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardHost.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.ContainerBase.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardEngine.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardService.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.core.StandardServer.start(catalina-5.5.17.jar.sodxk1ag.so)
at org.apache.catalina.startup.Catalina.start(catalina-5.5.17.jar.sodxk1ag.so)
at java.lang.reflect.Method.invoke(libgcj.so.7rh)
at org.apache.catalina.startup.Bootstrap.start(bootstrap.jar.so)
at org.apache.catalina.startup.Bootstrap.main(bootstrap.jar.so)
3-Aug-07 9:50:13 AM org.hibernate.connection.DriverManagerConnectionProvider close
INFO: cleaning up connection pool: jdbc:mysql://localhost:3306/rol
3-Aug-07 9:50:13 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive displaytag-examples-1.1.war
3-Aug-07 9:50:14 AM org.apache.catalina.core.ApplicationContext log
INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
3-Aug-07 9:50:14 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
3-Aug-07 9:50:14 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
3-Aug-07 9:50:14 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
3-Aug-07 9:50:14 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
3-Aug-07 9:50:15 AM org.apache.coyote.http11.Http11BaseProtocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
3-Aug-07 9:50:15 AM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
3-Aug-07 9:50:15 AM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/57 config=null
3-Aug-07 9:50:15 AM org.apache.catalina.storeconfig.StoreLoader load
INFO: Find registry server-registry.xml at classpath resource
3-Aug-07 9:50:15 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 5707 ms
3-Aug-07 9:51:49 AM org.apache.catalina.core.StandardWrapperValve invoke
INFO: Servlet action is currently unavailable


What can I do to fix this?? I have the cglib.jar in the lib folder of my webapp... what's wrong??

Thanks,

Paulo Ferreira


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.