2 Replies Latest reply on Jan 15, 2020 11:43 AM by bucpatr

    Using Older Versions of Hibernate in HibernateTools Ant

    bucpatr

      I'm in the process of trying to set up an ant task to generate a schema based on my existing JPA annotated classes. I was able to get the ant task to run, but it keeps failing with the exception

       

      java.lang.NoClassDefFoundError: org/dom4j/DocumentException

       

      From what I can tell, I'm missing a library somewhere, but I don't see anything for dom4j in the libs that come bundled with the plugin. Is there some way to define which logging solution the ant task should be using? Could this be caused by a mismatch between the hibernate version being used to compile my classes and the version that is bundled in hibernate-tools?

        • 1. Re: Using Older Versions of Hibernate in HibernateTools Ant
          koen.aers

          Hi,

           

          To be able to help you we will need some more information. Can you specify the exact versions of Java, JBoss Tools and the Hibernate plugins that you are using.

          Can you in addition post the entire stack trace that is produced? And to really help us out in tracking the issue, can you also maybe post a minimal (Maven) project along with some instructions to reproduce the problem?

           

          Cheers,

          Koen

          • 2. Re: Using Older Versions of Hibernate in HibernateTools Ant
            bucpatr

            I eventually found the problem. The dom4j lib was brought in as a top level jar in the eclipse plugins directory rather than being nested in org.jboss.tools.hibernate.runtime/lib. Once I fixed my classpath, the error went away.