senthil kumar - 2008-10-06

hi,
     when i try to connect to database(mysql) , i am getting the following error,

thanks in advance,

org.dom4j.DocumentException: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd Nested exception: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd
    at org.dom4j.io.SAXReader.read(SAXReader.java:358)
    at org.dom4j.io.SAXReader.read(SAXReader.java:219)
    at net.sf.hibernate.cfg.Configuration.addFile(Configuration.java:155)
    at net.sf.hibernator.HibernateConnection.createConnection(HibernateConnection.java:168)
    at net.sf.hibernator.views.ConnectionView$8.run(ConnectionView.java:199)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
Nested exception:
java.io.IOException: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
    at java.net.URL.openStream(Unknown Source)
    at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
    at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
    at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
    at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Source)
    at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown Source)
    at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
    at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
    at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
    at org.dom4j.io.SAXReader.read(SAXReader.java:339)
    at org.dom4j.io.SAXReader.read(SAXReader.java:219)
    at net.sf.hibernate.cfg.Configuration.addFile(Configuration.java:155)
    at net.sf.hibernator.HibernateConnection.createConnection(HibernateConnection.java:168)
    at net.sf.hibernator.views.ConnectionView$8.run(ConnectionView.java:199)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
rethrown as net.sf.hibernate.MappingException: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd Nested exception: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd
    at net.sf.hibernate.cfg.Configuration.addFile(Configuration.java:159)
    at net.sf.hibernator.HibernateConnection.createConnection(HibernateConnection.java:168)
    at net.sf.hibernator.views.ConnectionView$8.run(ConnectionView.java:199)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
Caused by: org.dom4j.DocumentException: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd Nested exception: Server returned HTTP response code: 400 for URL: http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd
    at org.dom4j.io.SAXReader.read(SAXReader.java:358)
    at org.dom4j.io.SAXReader.read(SAXReader.java:219)
    at net.sf.hibernate.cfg.Configuration.addFile(Configuration.java:155)
    ... 3 more

my hibernate property file:

<?xml version='1.0' encoding='utf-8'?>
<lt;!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<!-- Database connection settings -->
<property name="connection.driver_class">com.mysql.jdbc.Driver</property>
<property name="connection.url">jdbc:mysql://localhost:3306/techfaq</property>
<property name="connection.username">root</property>
<property name="connection.password"></property>
<!-- JDBC connection pool (use the built-in) -->
<property name="hibernate.c3p0.min_size">1</property>
<property name="hibernate.c3p0.max_size">4</property>
<property name="hibernate.c3p0.timeout">1800</property>
<property name="hibernate.c3p0.max_statements">50</property>
<!-- MySQL dialect//different for different Database -->
<property name="dialect">org.hibernate.dialect.MySQLDialect</property>
<!-- Enable Hibernate's automatic session context management -->
<property name="current_session_context_class">thread</property>
<!-- Disable the second-level cache -->
<property name="cache.provider_class">org.hibernate.cache.NoCacheProvider</property>
<!-- Echo all executed SQL to stdout -->
<property name="show_sql">true</property>
<property name="hbm2ddl.auto">update</property>
<mapping resource="Emp.hbm.xml"/>
</session-factory>
</hibernate-configuration>