-
1. Re: 4.0.x classloader NoClassDefFoundException
anil.saldhana Jan 25, 2005 3:40 PM (in response to jjmuhlestein)Why is the lib under META-INF? Move it one level higher and give it a shot!
-
2. Re: 4.0.x classloader NoClassDefFoundException
jjmuhlestein Jan 25, 2005 7:25 PM (in response to jjmuhlestein)To be honest, that's just how XDoclet built it. It's always worked that way and it does find all the other jar files in the lib directory.
-
3. Re: 4.0.x classloader NoClassDefFoundException
abcolson Mar 4, 2005 3:41 PM (in response to jjmuhlestein)I have a simplified version of the same problem. Using JBoss 4.0.0RC2 I have
app.ear
|__ app-ejb.jar
|__epi/projects/ComplianceProjectParticipantDTO.class
|__epi/projects/cmp/ComplianceProjectParticipant.class
The error isWARN [EJBDeployer] Verify failed; continuing
java.lang.NoClassDefFoundError: epi/projects/ComplianceProjectParticipantDTO
The class is there plain for everybody to see, not even buried in a sub jar as in the original post.
Here is some background...
Originally the app deployed fine. I decided to add DTOs (Data Transfer Objects/EJB View objects). Each EJB has a corresponding DTO class which mirrors the data methods but doesn't have the EJB functionality. Hence each EJB has getData()/setData() methods which utilizes its DTO counterpart.
Perhaps of curious note is that the EJB and its DTO are not in the same package (see above), but I don't know why this should matter.
I haven't yet tried any of the less desirable work-arounds; I was hoping the problem was fixed but noone posted the solution yet.
Any input is appreciated. -
4. Re: 4.0.x classloader NoClassDefFoundException
abcolson Mar 4, 2005 6:21 PM (in response to jjmuhlestein)Latest update...
I get the same errors with jboss-4.0.1sp1.
As stated previously by jjmuhlestein maybe the class loading scheme will be fixed in the next release.
Does anybody know when the next release will be?
Anything we can do in the mean time? -
5. Re: 4.0.x classloader NoClassDefFoundException
abcolson Mar 4, 2005 6:59 PM (in response to jjmuhlestein)Same errors in JBoss version 3.2.6.
BTW, the only differences ( from "jar tf") between the "bad" jar and one that works is the presence of the DTO classes in the bad jar (about 6) as noted previously in my first post. -
6. Re: 4.0.x classloader NoClassDefFoundException
abcolson Mar 7, 2005 9:39 PM (in response to jjmuhlestein)I found my problem. Recall the initial error was
java.lang.NoClassDefFoundError: epi/projects/ComplianceProjectParticipantDTO
This was very misleading because it had me chasing ghosts such as class loader issues. The real problem was that this class used a third party interface (DTO) that was not in the java class path for JBoss.
(See http://www.jboss.org/index.html?module=bb&op=viewtopic&t=51103)
Once I put the third party jar with the DTO interface under the lib directory for my JBoss deployment things worked fine.
BTW, I tested with JBoss versions 4.0.0RC2 and 4.0.1sp1, so it would appear that my problem had nothing to do with the above mentioned class loader issues with 4.0.0.