Uploaded image for project: 'JBoss ESB'
  1. JBoss ESB
  2. JBESB-3916

JBoss ESB 4.11, 4.12 generates hibernate error on JBoss AS 5.1.0.GA out of the box

    XMLWordPrintable

    Details

    • Steps to Reproduce:
      Hide

      Download JBoss AS 5.1.0.GA, extract to computer
      Download JBoss ESB 4.12, extract to computer
      Change $ESB_HOME/install/deployment.properties to point to JBoss AS 5.1.0.GA directory
      Run ant and install ESB to AS
      Switch to $EAP_HOME/bin and start JBoss AS
      After server starts up, the error above will be continually printed out to the console

      Show
      Download JBoss AS 5.1.0.GA, extract to computer Download JBoss ESB 4.12, extract to computer Change $ESB_HOME/install/deployment.properties to point to JBoss AS 5.1.0.GA directory Run ant and install ESB to AS Switch to $EAP_HOME/bin and start JBoss AS After server starts up, the error above will be continually printed out to the console

      Description

      When running JBoss ESB 4.11, or 4.12 in JBoss AS 5.1.0.GA, after server starts up the following error is continually logged:

      16:29:56,867 INFO  [Configuration] configuring from resource: hibernate.cfg.xml
      16:29:56,867 INFO  [Configuration] Configuration resource: hibernate.cfg.xml
      16:29:56,869 DEBUG [DTDEntityResolver] trying to resolve system-id [http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd]
      16:29:56,869 DEBUG [DispatcherThread] failed to retrieve next waiting due job
      org.hibernate.HibernateException: Could not parse configuration: hibernate.cfg.xml
              at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1528)
              at org.hibernate.cfg.Configuration.configure(Configuration.java:1462)
              at org.jbpm.db.hibernate.HibernateHelper.createConfiguration(HibernateHelper.java:89)
              at org.jbpm.persistence.db.DbPersistenceServiceFactory.getConfiguration(DbPersistenceServiceFactory.java:75)
              at org.jbpm.persistence.db.DbPersistenceServiceFactory.getSessionFactory(DbPersistenceServiceFactory.java:104)
              at org.jbpm.persistence.db.DbPersistenceService.getSessionFactory(DbPersistenceService.java:93)
              at org.jbpm.persistence.jta.JtaDbPersistenceService.getTransactionManager(JtaDbPersistenceService.java:100)
              at org.jbpm.persistence.jta.JtaDbPersistenceService.getTransactionStatus(JtaDbPersistenceService.java:88)
              at org.jbpm.persistence.jta.JtaDbPersistenceService.<init>(JtaDbPersistenceService.java:50)
              at org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory.openService(JtaDbPersistenceServiceFactory.java:61)
              at org.jbpm.svc.Services.getService(Services.java:160)
              at org.jbpm.svc.Services.getPersistenceService(Services.java:197)
              at org.jbpm.JbpmContext.getPersistenceService(JbpmContext.java:695)
              at org.jbpm.JbpmContext.getJobSession(JbpmContext.java:639)
              at org.jbpm.job.executor.DispatcherThread.getNextDueDateWithinIdleInterval(DispatcherThread.java:193)
              at org.jbpm.job.executor.DispatcherThread.run(DispatcherThread.java:70)
      Caused by: org.dom4j.DocumentException: www.hibernate.org Nested exception: www.hibernate.org
              at org.dom4j.io.SAXReader.read(SAXReader.java:484)
              at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1518)
      

      Problem appears to be caused by a mismatch with the DTD name in the deploy/jbpm.esb/hibernate.cfg.xml and hibernate-core.jar/hibernate-configuration-3.0.dtd.

      hibernate.cfg.xml uses the following:

      <?xml version='1.0' encoding='utf-8'?>
      <!DOCTYPE hibernate-configuration PUBLIC
        "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
        "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
      

      However, the hibernate-configuration-3.0.dtd uses http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd.

      Changing hibernate.cfg.xml to use the above URL fixes the errors for JBoss AS 5.1.0.GA.

      JBoss AS 6.1.0.Final has no problem. The hibernate-configuration-3.0.dtd in AS6 uses the www.hibernate.org address.

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            ian.walker Ian Walker (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: