Hello I'm using Hibernate Synchronizer and I have this structure project. When I execute Prova.java class as Main process hibernate dumps me this:
Can you say me what happens. I'm wondering
Thanks in advance
Main process -->
Code:
public static void main(String[] args) {
// TODO Auto-generated method stub
com.gmsoft.model.Rols rol = new com.gmsoft.model.Rols((byte)60);
rol.setDescripcio("Hibernate");
com.gmsoft.model.dao.RolsDAO rolDAO = new com.gmsoft.model.dao.RolsDAO();
System.out.println("intentant guardar un rol...");
rolDAO.save(rol,rolDAO.getSession());
System.out.println("rol guardat!!!");
}
intentant guardar un rol...
Code:
16-oct-2006 20:19:14 org.hibernate.cfg.Environment <clinit>
INFO: Hibernate 3.1.3
16-oct-2006 20:19:15 org.hibernate.cfg.Environment <clinit>
INFO: hibernate.properties not found
16-oct-2006 20:19:15 org.hibernate.cfg.Environment <clinit>
INFO: using CGLIB reflection optimizer
16-oct-2006 20:19:15 org.hibernate.cfg.Environment <clinit>
INFO: using JDK 1.4 java.sql.Timestamp handling
16-oct-2006 20:19:15 org.hibernate.cfg.Configuration configure
INFO: configuring from resource:
16-oct-2006 20:19:15 org.hibernate.cfg.Configuration getConfigurationInputStream
INFO: Configuration resource:
16-oct-2006 20:19:15 org.hibernate.util.XMLHelper$ErrorLogger error
GRAVE: Error parsing XML: (1) Content is not allowed in prolog.
Exception in thread "main" org.hibernate.HibernateException: Could not parse configuration:
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1376)
at org.hibernate.cfg.Configuration.configure(Configuration.java:1310)
at com.gmsoft.model.base._BaseRootDAO.initialize(_BaseRootDAO.java:104)
at com.gmsoft.model.base._BaseRootDAO.initialize(_BaseRootDAO.java:88)
at com.gmsoft.model.base._BaseRootDAO.getSessionFactory(_BaseRootDAO.java:145)
at com.gmsoft.model.base._BaseRootDAO.getSession(_BaseRootDAO.java:64)
at com.gmsoft.model.base._BaseRootDAO.getSession(_BaseRootDAO.java:42)
at com.gmsoft.Prova.main(Prova.java:15)
Caused by: org.dom4j.DocumentException: Error on line 1 of document : Content is not allowed in prolog. Nested exception: Content is not allowed in prolog.
at org.dom4j.io.SAXReader.read(SAXReader.java:482)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1366)
... 7 more