-->
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.  [ 7 posts ] 
Author Message
 Post subject: "Mapping Error..."
PostPosted: Mon Apr 05, 2004 4:25 am 
Newbie

Joined: Sun Apr 04, 2004 5:00 am
Posts: 13
Dear Seniors...

i was in a full search for Hibernate+struts+Tomcat+Mysql...
i got ur example application in this following link.
http://homepage.mac.com/edahand/project ... mple1.html
after all the instructions....i use Ant to buid the appln...
and when i call the link
but i call the following link ...

http://localhost:8080/example1/items.do

i am getting this kind of Mapping Eroor....

---------------------------------
java.lang.RuntimeException: net.sf.hibernate.MappingException: Error reading resource: com/celestials/example1/Item.hbm.xml
at com.celestials.example1.ConnectionFactory.(Unknown Source)
at com.celestials.example1.ConnectionFactory.getInstance(Unknown Source)
at com.celestials.example1.ItemService.getItemList(Unknown Source)
---------------------------------

but...i have item.hbm.xml at the
<classes\com\celestials\example1> directory...

Now...wht shd i do to overcome this.....

pls guide me to make this(my) application "SUCCESS".

thanx...expecting ur quick reply.
thanx in advance!
ur Junior,

-Munas.
(very new to Hibernate Concepts)


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 05, 2004 9:49 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
item.hbm.xml => Item.hbm.xml

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 05, 2004 11:58 am 
Newbie

Joined: Sun Apr 04, 2004 5:00 am
Posts: 13
dear senior Mr.Emmanuel...

i have checked...the file name is Item.hbm.xml only..
wht shd i do...?

pls gimme a sol.
ur Junior
Munas.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 05, 2004 2:16 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
Then show full exception stacktrace and full log (there should be a cause exception)

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 06, 2004 1:10 am 
Newbie

Joined: Sun Apr 04, 2004 5:00 am
Posts: 13
dear Senior Immanuel !

here is the whole stack trace...

expecting ur reply...

ur Junior,

-Munas

--------------------------------------------------------------------------------
Apache Tomcat/4.0.6 - HTTP Status 500 - Internal Server Error

--------------------------------------------------------------------------------

type Exception report

message Internal Server Error

description The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request.

exception

java.lang.RuntimeException: net.sf.hibernate.MappingException: Error reading resource: com/celestials/example1/Item.hbm.xml
at com.celestials.example1.ConnectionFactory.(Unknown Source)
at com.celestials.example1.ConnectionFactory.getInstance(Unknown Source)
at com.celestials.example1.ItemService.getItemList(Unknown Source)
at org.apache.jsp.AddItem$jsp._jspService(AddItem$jsp.java:154)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:201)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:683)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:431)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:355)
at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274)
at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:320)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2347)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1027)
at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1125)
at java.lang.Thread.run(Thread.java:534)
Caused by: net.sf.hibernate.MappingException: Error reading resource: com/celestials/example1/Item.hbm.xml
at net.sf.hibernate.cfg.Configuration.addClass(Configuration.java:336)
... 52 more
Caused by: net.sf.hibernate.MappingException: org.dom4j.DocumentException: null Nested exception: null
at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:293)
at net.sf.hibernate.cfg.Configuration.addClass(Configuration.java:333)
... 52 more
Caused by: org.dom4j.DocumentException: null Nested exception: null
at org.dom4j.io.SAXReader.read(SAXReader.java:358)
at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:283)
... 53 more



--------------------------------------------------------------------------------


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 07, 2004 6:41 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
Quote:
Caused by: org.dom4j.DocumentException: null Nested exception: null
at org.dom4j.io.SAXReader.read(SAXReader.java:358)
at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:283)

Check the dom4j src, you may find the real cause.
And stop calling me senior, it sounds like I'm 70 years old ;-)

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 07, 2004 1:39 pm 
Newbie

Joined: Sun Apr 04, 2004 5:00 am
Posts: 13
dear Emmy...

i am having that "dom4j.jar" file in all my folowing
1...Tomcat4\lib
2...Tomcat\common\lib
3...Tomcat\webapps\example1\lib directories..
now wht shd i do?..pls be brief in that..

-Munas.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 7 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.