1 Reply Latest reply on Jul 2, 2004 2:40 PM by tonylampada

    NoClassDefFoundError and hibernate2.jar

    Andre Silva Newbie

      Hi all,

      I've put hibernate2.jar in $JBOSS_HOME/server/default/lib, but when I try to use hibernate, the following error occurs:

      java.lang.NoClassDefFoundError: net/sf/hibernate/collection/Set
       at net.sf.hibernate.type.TypeFactory.set(TypeFactory.java:200)
       at net.sf.hibernate.mapping.Set.getCollectionType(Set.java:29)
       at net.sf.hibernate.mapping.Collection.getType(Collection.java:275)
       at net.sf.hibernate.cfg.Binder.bindProperty(Binder.java:443)
       at net.sf.hibernate.cfg.Binder.createProperty(Binder.java:1070)
       at net.sf.hibernate.cfg.Binder.propertiesFromXML(Binder.java:1050)
       at net.sf.hibernate.cfg.Binder.bindRootClass(Binder.java:361)
       at net.sf.hibernate.cfg.Binder.bindRoot(Binder.java:1243)
       at net.sf.hibernate.cfg.Configuration.add(Configuration.java:249)
       at net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:
      285)


      No matter what I do, I get this error. I checked and there is no another hibernate2.jar file deployed, no class duplicated, the net/sf/hibernate/collection/Set class is in the hibernate2.jar.
      Probably it's a jboss class loader problem. Someone has already had this problem? Did someone fix this problem?

      Thanks,

      afsilva