Hello Everybody,
i am making a web application which is based on GWT instantiation.. at server end i want to use hibernate for accessing database but when i run it on eclipse 3.2 having GWT instantiation plug in(after writing all the code of client side and server side including use of hibernate)it is giving this error
Error is org.hibernate.HibernateException: Could not parse configuration: /hibernate.cfg.xml
which comes for these lines in the server side code
SessionFactory sessionFactory = new Configuration().configure().buildSessionFactory();
Session session =sessionFactory.openSession();
Manager manager = new Manager(session);
user=manager.searchUser(username);
where user is object of database entity and manager is the class which access the database ...
my hibernate.cfg.xml is as following
///////////////////////////////
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="connection.url">
jdbc:mysql://localhost:3306/test
</property>
<property name="connection.driver_class">
com.mysql.jdbc.Driver
</property>
<property name="connection.username">
root
</property>
<property name="connection.password">
dexter
</property>
<!-- Set AutoCommit to true -->
<property name="connection.autocommit">
true
</property>
<!-- SQL Dialect to use. Dialects are database specific -->
<property name="dialect">
org.hibernate.dialect.MySQLDialect
</property>
<!-- Mapping files -->
<mapping resource="com/visualbuilder/hibernate/User.hbm.xml" />
</session-factory>
</hibernate-configuration>
///////////////////////////////
what i think that when i run this as GWT application on eclipse 3.2 it is giving this error due to absence of hibernate lib at server end i am not so clear...
if somebody will help me i will be thankful to him...
please reply soonn....