-
Aug 29th, 2006, 09:28 AM
#1
java.lang.NoClassDefFoundError: org/dom4j/DocumentException dom4j-1.6.1.jar added
Hi from newbie 
I'm having this error:
org.apache.jasper.JasperException: javax.servlet.jsp.JspException: javax.faces.FacesException: javax.faces.el.EvaluationException: javax.faces.FacesException: javax.faces.FacesException: Can't instantiate class: 'pkg.bean.ServiceLocatorBean'.. class pkg.bean.ServiceLocatorBean : org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationExcepti on: Could not instantiate bean class [org.springframework.orm.hibernate3.LocalSessionFac toryBean]: Constructor threw exception; nested exception is java.lang.NoClassDefFoundError: org/dom4j/DocumentException
org.apache.jasper.servlet.JspServletWrapper.handle JspException(JspServletWrapper.java:510)
org.apache.jasper.servlet.JspServletWrapper.servic e(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFil e(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspSe rvlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet .java:802)
I keep reciving this error though that i've added the dom4j-1.6.1.jar to the project. Any idea why?
I'm using JSF 1.2 Spring 1.2.8. Hibernate 3.1
Thx for any kind of help
-
Aug 29th, 2006, 09:47 AM
#2
Maybe a stupid question but is the dom4j-1.6.1.jar in your WEB-INF/lib directory?
-
Aug 31st, 2006, 01:26 AM
#3
Hi from newbie 
Yes my dom4j-1.6.1.jar file is in the WEB-INF\lib as well as in common\lib under tomcat dir. I've also added it via the eclipse package manager. That's why it's so strange for me that the package couldn't be found.
Thx for any help
-
Aug 31st, 2006, 02:03 AM
#4
Hi 
I solved the problem by modifing the build.xml file. Thx mdeinum for your help
-
Jun 29th, 2012, 07:39 AM
#5
Hi there,
I have the same problem. Can you tell me how you fixed it. I mean how did you modify the build.xml.
Thx for reply
-
Jul 2nd, 2012, 02:29 AM
#6
Since the dom4j is already inside Tomcat's common libs, you shouldn't add it to your web-inf/lib folder. Alien01 probably solved by excluding the jar from the ant build copy command.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules