1 Reply Latest reply on Oct 6, 2004 1:00 AM by jmcada

    OReilly cos.jar - NoClassDefFoundError

    dsinclair

      Im new to JBoss, and I'm pulling my hair out trying to get OReilly's cos.jar File Upload classes to work. I'm compiling using Ant, and it compiles fine (no errors). but when i call my servlet, i get the following runtime error:

      java.lang.NoClassDefFoundError: com/oreilly/servlet/MultipartWrapper

      I guess JBoss can't find the cos.jar file, but i have no idea why. cos.jar is added in the ear file (in the war file in WEB-INF/lib). On my Mac OSX server, cos.jar is also located in /Library/Java/Extensions/ and /Library/JBoss/3.2/server/default/lib/ . I expect that one of my xml files needs a reference to tell JBoss to look in war /WEB-INF/lib. Whats the secret to getting JBoss to see 3rd party jars? I can post my xml files if needed.
      Any help is greatly appreciated.

      Davy

        • 1. Re: OReilly cos.jar - NoClassDefFoundError
          jmcada

          jar files müssen bei webapps im web-inf/lib liegen,
          also das jar file dahinkopieren, und dann sollte es klappen
          vorallem da es ja ungepackt in web-inf/classes klappt.

          ...und anschliessend den Tomcat-Dienst neu starten, damit er die Klassen in den jars auch findet.

          Vielen Dank! Das war's.
          Tja, kaum macht man's richtig, schon funktionierts!