-->
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: hibernate-mapping-3.0.dtd reference problem
PostPosted: Thu Jan 20, 2011 11:05 am 
Newbie

Joined: Wed Jan 19, 2011 6:27 pm
Posts: 2
Referenced file contains errors (http://hibernate.sourceforge.net/hibern ... ng-3.0.dtd). For more
information, right click on the message and select "Show Details..."

I have got the above error yesterday and i have read all over the internet finally i have heard that JBoss server down. If this is the case after some time JBoss's Server (Site) is up and running and if i hit this URL "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" i am able to download the dtd.

Second thing i have tried was downloaded the DTD and copied it in the same directory of all the hbm.xml file presents. and then i have modified the hbm.xml files to something like the following:

1. <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN" "hibernate-mapping-3.0.dtd">
2. <!DOCTYPE hibernate-mapping SYSTEM "<PATH>/hibernate-mapping-3.0.dtd">

1st Option couldn't find the path properly
2nd Option is working fine but we cannot change all the hbm files to point out the directory which we stored.

Then i have actually tried to create a sample project with the same configuration (hbm, Spring etc..) i doesnt show up the error message in the hbm file.

Sample HBM:

<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
<class name="db.Test" table="test" catalog="test">
<id name="id" type="java.lang.Integer">
<meta attribute="use-in-equals">true</meta>
<column name="id" />
<generator class="identity" />
</id>
<property name="name" type="string">
<column name="name" length="45" not-null="true" />
</property>
<property name="createdDate" type="timestamp">
<column name="createdDate" length="19" not-null="true" />
</property>
<property name="isTrue" type="boolean">
<column name="isTrue" not-null="true" />
</property>
<property name="testId" type="string">
<column name="testId" length="45" not-null="true" />
</property>
</class>
</hibernate-mapping>

Don't know what to do. Can anyone help me out this problem?


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Fri Jan 21, 2011 1:36 pm 
Regular
Regular

Joined: Wed Mar 23, 2005 8:43 am
Posts: 105
Location: Moscow, Russia
Same problem for me. +1 to help request.

_________________
Best Regards


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Fri Jan 21, 2011 4:29 pm 
Newbie

Joined: Fri Jan 21, 2011 4:22 pm
Posts: 1
Same here, I'm also getting the following in my logs on a newly deployed app and startup is failing. Did hibernate-mapping-3.0.dtd get changed somehow? This was all working earlier in the week

2011-01-21 11:51:46,741 671 ERROR [org.hibernate.util.XMLHelper] (main:) Error parsing XML: file:/home/ben/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/foobar/WEB-INF/classes/hibernate.cfg.xml(5) Element type "hibernate-configuration" must be declared.
2011-01-21 11:51:46,760 690 ERROR [org.hibernate.util.XMLHelper] (main:) Error parsing XML: file:/home/ben/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/foobar/WEB-INF/classes/hibernate.cfg.xml(6) Element type "session-factory" must be declared.
2011-01-21 11:51:46,772 702 ERROR [org.hibernate.util.XMLHelper] (main:) Error parsing XML: file:/home/ben/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/foobar/WEB-INF/classes/hibernate.cfg.xml(8) The content of element type "property" must match "(meta*,(column|formula)*,type?)".
2011-01-21 11:51:46,778 708 ERROR [org.hibernate.util.XMLHelper] (main:) Error parsing XML: file:/home/ben/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/foobar/WEB-INF/classes/hibernate.cfg.xml(26) Element type "mapping" must be declared.


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Mon Jan 24, 2011 10:59 am 
Senior
Senior

Joined: Tue Jun 21, 2005 10:18 am
Posts: 135
Location: South Carolina, USA
Try replacing the sourceforge URL with

Code:
http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Mon Jan 24, 2011 11:01 am 
Regular
Regular

Joined: Wed Mar 23, 2005 8:43 am
Posts: 105
Location: Moscow, Russia
It seems this issue has been fixed today for me.

_________________
Best Regards


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Mon Jan 24, 2011 12:44 pm 
Newbie

Joined: Wed Jan 19, 2011 4:38 pm
Posts: 1
This is still an issue for me.
When I changed to http://www.hibernate.org/dtd/hibernate- ... on-3.0.dtd I get more errors.


Top
 Profile  
 
 Post subject: Re: hibernate-mapping-3.0.dtd reference problem
PostPosted: Tue Jan 25, 2011 3:25 pm 
Newbie

Joined: Tue Jan 25, 2011 3:15 pm
Posts: 2
this worked for me

viewtopic.php?f=1&t=995303&p=2440819#p2440819


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.