2 Replies Latest reply on May 16, 2006 8:47 AM by koen.aers

    where do you place hibernate config file in webapp?

    greg823

      I can run jbpm as standalone executable with no problem because I set the classpath.
      When deployed as webapp, I get the following exception.

      My question is: where do you place the hibernate.cfg.xml under webapp
      so that jbpm will work with hibernate?
      I have no problem with jbpm configuration file because I supply its path
      to the JbpmConfiguration during runtime using ServletContext.getRealpath()
      Thanks for your help.


      org.hibernate.HibernateException: hibernate.cfg.xml not found
       org.hibernate.util.ConfigHelper.getResourceAsStream(ConfigHelper.java:147)
       org.hibernate.cfg.Configuration.getConfigurationInputStream(Configuration.java:1265)
       org.hibernate.cfg.Configuration.configure(Configuration.java:1287)
       org.jbpm.db.hibernate.HibernateHelper.createConfiguration(HibernateHelper.java:90)
       org.jbpm.persistence.db.DbPersistenceServiceFactory.getConfiguration(DbPersistenceServiceFactory.java:68)
       org.jbpm.persistence.db.DbPersistenceServiceFactory.getSessionFactory(DbPersistenceServiceFactory.java:90)
       org.jbpm.persistence.db.DbPersistenceService.getSessionFactory(DbPersistenceService.java:74)
       org.jbpm.persistence.db.DbPersistenceService.getSession(DbPersistenceService.java:79)
       org.jbpm.persistence.db.DbPersistenceService.getGraphSession(DbPersistenceService.java:216)
       org.jbpm.JbpmContext.getGraphSession(JbpmContext.java:427)
       org.jbpm.JbpmContext.deployProcessDefinition(JbpmContext.java:166)