Win a copy of 97 Things Every Java Programmer Should Know this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

Migration of Hibernate 2.0 to 3.0

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Am migrating my applications from hibernate 2.0 to 3.0 . After changing all the config.xml , hbm.xml and my class files from hibernate 2.0 specification to hibernate 3.0 specification . Am getting the below listed error.. please help me out.. Thanks very much in advance.. For the past 5 days am trying this..

My hibernate.cfg.xml file is

<?xml version="1.0" encoding="utf-8"?>

<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD//EN"

"http://hibernate.sourceforge.net/hibernate-configuration-2.0.dtd">;

<hibernate-configuration>

<session-factory>

<property name="connection.datasource">weblogic.jdbc.jts.WAMUPool</property>

<property name="dialect">org.hibernate.dialect.Oracle9Dialect</property>

<property name="hibernate.query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</property>

<!-- <property name="show_sql">true</property> -->

<mapping resource="/com/wamu/dashboard/addressbook/Contact.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/addressbook/EmailAddress.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/addressbook/Group.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/crm/APCampaign.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/crm/APCollateral.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/crm/APLead.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/crm/APTreatment.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/crm/RTIntent.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/doforms/BrokerLfcInfo.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/hotlinks/HotLink.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/pricing/ProductPriceSheet.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/security/permission/Permission.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/security/permission/UserTargetedContent.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/newsflash/Newsflash.hbm.xml"/>

<mapping resource="/com/wamu/dashboard/newsflash/Audience.hbm.xml"/>

<mapping resource="com/wamu/dashboard/subscriptions/DashboardEmailRecord.hbm.xml"/>

<mapping resource="com/wamu/dashboard/subscriptions/DashboardEmailRecordAM.hbm.xml"/>

<mapping resource="com/wamu/dashboard/subscriptions/DashboardEmailRecordCompany.hbm.xml"/>

</session-factory>

</hibernate-configuration>


My hbm file is named as hotlink.hbm.xml and it is given below.

<?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 default-cascade="none">

<class name="com.wamu.dashboard.hotlinks.HotLink" table="HOT_LINK">

<id name="hotLinkId" type="integer" unsaved-value="null" >

<column name="HOT_LINK_ID" sql-type="integer" not-null="true"/>

<generator class="sequence">

<param name="sequence">HOT_LINK_SEQ</param>

</generator>

</id>

<property name="displayName">

<column name="DISPLAY_NAME" sql-type="varchar(60)" />

</property>

<property name="userPermissionCode">

<column name="USER_PERMISSION_CODE" sql-type="varchar(20)" />

</property>

<property name="link">

<column name="LINK" sql-type="varchar(60)" not-null="true"/>

</property>

</class>

<query name="getHotLinksByPermissionCode"><![CDATA[select link, userTargetedContent.displayName from HotLink link, UserTargetedContent userTargetedContent where link.userPermissionCode = userTargetedContent.userPermissionCode and link.userPermissionCode in (:userPermissionCode) order by link.userPermissionCode, link.displayName]]></query>

</hibernate-mapping>


<Jan 4, 2007 1:27:34 AM PST> <Error> <T3Services> <000000> <org.hibernate.cfg.Configuration: Could not configure datastore from input stream

org.dom4j.DocumentException: hibernate.sourceforge.net Nested exception: hibernate.sourceforge.net
at org.dom4j.io.SAXReader.read(SAXReader.java:358)
at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:395)
at org.hibernate.cfg.Configuration.addResource(Configuration.java:446)
at org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1313)
at org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1285)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1267)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1234)
at org.hibernate.cfg.Configuration.configure(Configuration.java:1177)
at com.wamu.dashboard.util.hibernate.HibernateUtil.init(HibernateUtil.java:295)
at com.wamu.dashboard.util.hibernate.HibernateUtil.<clinit>(HibernateUtil.java:75)
at com.wamu.dashboard.util.hibernate.HibernateCommandExecutor.getSession(HibernateCommandExecutor.java:76)
at com.wamu.dashboard.util.hibernate.HibernateCommand.this(HibernateCommand.java:26)
at com.wamu.dashboard.util.hibernate.HibernateCommand.<init>(HibernateCommand.java:31)
at com.wamu.dashboard.security.permission.GetUserTargetedContentCommand.<init>(GetUserTargetedContentCommand.java:30)
at com.wamu.dashboard.security.permission.web.GetUserTargetedContentServlet.myService(GetUserTargetedContentServlet.java:49)
at com.wamu.dashboard.util.web.BaseServlet.service(BaseServlet.java:154)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:996)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:419)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:315)
at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:626)
at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:412)
at jsp_servlet._admin._hotlinks.__index._jspService(__index.java:276)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:33)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:996)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:419)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:463)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:315)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6456)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3661)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2630)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)
Nested exception:
java.net.UnknownHostException: hibernate.sourceforge.net
at java.net.InetAddress.getAllByName0(InetAddress.java:1016)
at java.net.InetAddress.getAllByName0(InetAddress.java:981)
at java.net.InetAddress.getAllByName(InetAddress.java:975)
at weblogic.net.http.HttpClient.openServer(HttpClient.java:263)
at weblogic.net.http.HttpClient.openServer(HttpClient.java:329)
at weblogic.net.http.HttpClient.<init>(HttpClient.java:128)
at weblogic.net.http.HttpURLConnection.getHttpClient(HttpURLConnection.java:129)
at weblogic.net.http.HttpURLConnection.getInputStream(HttpURLConnection.java:331)
at weblogic.net.http.SOAPHttpURLConnection.getInputStream(SOAPHttpURLConnection.java:28)
at java.net.URL.openStream(URL.java:913)
at weblogic.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityManager.java:836)
at weblogic.apache.xerces.impl.XMLEntityManager.startDTDEntity(XMLEntityManager.java:796)
at weblogic.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(XMLDTDScannerImpl.java:275)
at weblogic.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(XMLDocumentScannerImpl.java:841)
at weblogic.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:329)
at weblogic.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:525)
at weblogic.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:581)
at weblogic.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
at weblogic.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1175)
at weblogic.xml.jaxp.WebLogicXMLReader.parse(WebLogicXMLReader.java:135)
at weblogic.xml.jaxp.RegistryXMLReader.parse(RegistryXMLReader.java:152)
at org.dom4j.io.SAXReader.read(SAXReader.java:339)
at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:395)
at org.hibernate.cfg.Configuration.addResource(Configuration.java:446)
at org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1313)
at org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1285)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1267)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1234)
at org.hibernate.cfg.Configuration.configure(Configuration.java:1177)
at com.wamu.dashboard.util.hibernate.HibernateUtil.init(HibernateUtil.java:295)
at com.wamu.dashboard.util.hibernate.HibernateUtil.<clinit>(HibernateUtil.java:75)
at com.wamu.dashboard.util.hibernate.HibernateCommandExecutor.getSession(HibernateCommandExecutor.java:76)
at com.wamu.dashboard.util.hibernate.HibernateCommand.this(HibernateCommand.java:26)
at com.wamu.dashboard.util.hibernate.HibernateCommand.<init>(HibernateCommand.java:31)
at com.wamu.dashboard.security.permission.GetUserTargetedContentCommand.<init>(GetUserTargetedContentCommand.java:30)
at com.wamu.dashboard.security.permission.web.GetUserTargetedContentServlet.myService(GetUserTargetedContentServlet.java:49)
at com.wamu.dashboard.util.web.BaseServlet.service(BaseServlet.java:154)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:996)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:419)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:315)
at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:626)
at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:412)
at jsp_servlet._admin._hotlinks.__index._jspService(__index.java:276)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:33)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:996)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:419)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:463)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:315)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6456)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3661)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2630)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)
>
 
Sheriff
Posts: 67401
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is your third post of the same question.

Please post a question only once!
 
The moustache of a titan! The ad of a flea:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic