-->
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.  [ 3 posts ] 
Author Message
 Post subject: No base URI; hope URI is absolute
PostPosted: Tue Dec 23, 2003 9:50 am 
Regular
Regular

Joined: Tue Oct 14, 2003 11:11 pm
Posts: 62
Location: Brasil/Curitiba
Hi,

I'm having warnings when I configure a SessionFactory,

could anyone help me please?

thank you.

Code:
11:44:42,063  INFO Environment:401 - Hibernate 2.0.1
11:44:42,094  INFO Environment:435 - loaded properties from resource hibernate.properties: {hibernate.connection.driver_class=oracle.jdbc.driver.OracleDriver, hibernate.cglib.use_reflection_optimizer=true, hibernate.dialect=net.sf.hibernate.dialect.OracleDialect, hibernate.connection.username=crea, hibernate.connection.url=jdbc:oracle:thin:@wsdevel:1521:oradevel, hibernate.show_sql=true, hibernate.connection.password=crea, hibernate.connection.pool_size=30, hibernate.statement_cache.size=50}
11:44:42,104  INFO Environment:450 - using CGLIB reflection optimizer
11:44:42,114  INFO Environment:460 - JVM proxy support: true

11:44:42,124  INFO Configuration:283 - Mapping resource: net/wasys/crea/model/OpiniaoVO.hbm.xml

11:44:42,384  WARN XMLHelper:43 - Warning parsing XML: XML InputStream(1)
org.xml.sax.SAXParseException: URI was not reported to parser for entity [document]
   at gnu.xml.aelfred2.SAXDriver.warn(SAXDriver.java:934)
   at gnu.xml.aelfred2.SAXDriver.startExternalEntity(SAXDriver.java:631)
   at gnu.xml.aelfred2.XmlParser.pushURL(XmlParser.java:3358)
   at gnu.xml.aelfred2.XmlParser.doParse(XmlParser.java:159)
   at gnu.xml.aelfred2.SAXDriver.parse(SAXDriver.java:320)
   at gnu.xml.aelfred2.XmlReader.parse(XmlReader.java:294)
   at org.dom4j.io.SAXReader.read(SAXReader.java:339)
   at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:252)
   at net.sf.hibernate.cfg.Configuration.addClass(Configuration.java:286)
   at net.wasys.crea.hibernate.HibernateThreadLocalSession.init(HibernateThreadLocalSession.java:190)
   at net.wasys.crea.hibernate.HibernateThreadLocalSession.<clinit>(HibernateThreadLocalSession.java:46)
   at net.wasys.crea.test.Teste.main(Teste.java:27)
11:44:42,434  WARN XMLHelper:43 - Warning parsing XML: XML InputStream(4)
org.xml.sax.SAXParseException: No base URI; hope URI is absolute: http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd
   at gnu.xml.aelfred2.SAXDriver.warn(SAXDriver.java:934)
   at gnu.xml.aelfred2.XmlParser.readExternalIds(XmlParser.java:2399)
   at gnu.xml.aelfred2.XmlParser.parseDoctypedecl(XmlParser.java:804)
   at gnu.xml.aelfred2.XmlParser.parseProlog(XmlParser.java:522)
   at gnu.xml.aelfred2.XmlParser.parseDocument(XmlParser.java:414)
   at gnu.xml.aelfred2.XmlParser.doParse(XmlParser.java:167)
   at gnu.xml.aelfred2.SAXDriver.parse(SAXDriver.java:320)
   at gnu.xml.aelfred2.XmlReader.parse(XmlReader.java:294)
   at org.dom4j.io.SAXReader.read(SAXReader.java:339)
   at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:252)
   at net.sf.hibernate.cfg.Configuration.addClass(Configuration.java:286)
   at net.wasys.crea.hibernate.HibernateThreadLocalSession.init(HibernateThreadLocalSession.java:190)
   at net.wasys.crea.hibernate.HibernateThreadLocalSession.<clinit>(HibernateThreadLocalSession.java:46)
   at net.wasys.crea.test.Teste.main(Teste.java:27)


and my mapping file:

Code:
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC
        "-//Hibernate/Hibernate Mapping DTD 2.0//EN"
        "http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd">
   
<hibernate-mapping>

<class
    name="net.wasys.crea.model.OpiniaoVO"
    table="OPINIAO"
>
    <id
        name="id"
        type="java.lang.Long"
        column="OPINIAOID"
    >
        <generator class="sequence">
           <param name="sequence">Opiniao_serial</param>   
        </generator>
    </id>

    <property
        name="dataHoraOpiniao"
        type="java.sql.Timestamp"
        column="DATAHORAOPINIAO"
        not-null="true"
        length="7"
    />
    <property
        name="nomeUsuario"
        type="java.lang.String"
        column="NOMEUSUARIO"
        not-null="true"
        length="60"
    />
    <property
        name="emailUsuario"
        type="java.lang.String"
        column="EMAILUSUARIO"
        not-null="true"
        length="100"
    />
    <property
        name="link"
        type="java.lang.String"
        column="LINK"
        not-null="true"
        length="255"
    />
    <property
        name="mensagem"
        type="java.lang.String"
        column="MENSAGEM"
        not-null="true"
        length="500"
    />

</class>
</hibernate-mapping>

_________________
Ricardo Lecheta


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 23, 2003 11:01 am 
Newbie

Joined: Thu Dec 11, 2003 5:48 pm
Posts: 3
Had the same error message and simply added the hibernate dtd to the classpath.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 23, 2003 11:28 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
Dom4j may not manage EntityResolver as Xerces do.

_________________
Emmanuel


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