cancel
Showing results for 
Search instead for 
Did you mean: 

NoClassDefFoundError When Accessing Class from EJB (from WD)

detlev_beutner
Active Contributor
0 Kudos

Hi there,

Already posted within the WD forum, but absolute no comment so far... maybe here it will fit better. This one drives me crazy (but maybe, I'm overlooking some simple setting...):

We have a WD project, an EAR project, an EJB project. Within the EJB project, we have some EJB and some helper classes.

Problem: The WD calls the EJB, and when within the EJB a helper class should get into the game, a NoClassDefFoundError is thrown. This is really strange in my eyes, as the EJB itself could be resolved and we are talking of a class within the same JAR!

The WD project has a SharingReference to the EAR project. The EAR encapsulates the EJB JAR, and this definitely contains the class the server later is complaining about.

The stack trace is like this:

com.sap.engine.services.ejb.exceptions.BaseEJBException: Exception in method getList.
	at com.xxx.sessionfacade.ejb.ManagerSBLocalLocalObjectImpl0_0.getList(ManagerSBLocalLocalObjectImpl0_0.java:191)
	at com.xxx.client.bd.SomeBD.getTrackingList(TrackingBD.java:68)
	[...]
	at com.sap.tc.webdynpro.progmodel.context.Node.supplyElements(Node.java:403)
	at com.sap.tc.webdynpro.progmodel.context.Node.getElementList(Node.java:346)
	at com.sap.tc.webdynpro.progmodel.context.Node.getElements(Node.java:334)
	at com.sap.tc.webdynpro.progmodel.context.Node.size(Node.java:718)
	at com.xxx.wd.MainComp.filter(MainComp.java:298)
	[...]
	at com.sap.tc.webdynpro.progmodel.generation.DelegatingComponent.doInit(DelegatingComponent.java:95)
	[...]
Caused by: java.lang.NoClassDefFoundError: com.xxx.business.dao.SomeDAO
	at java.lang.Class.initialize(Class.java:307)
	at com.xxx.sessionfacade.ejb.ManagerSBBean.getList(ManagerSBBean.java:75)
	[...]
	at com.sap.tc.webdynpro.progmodel.context.Node.supplyElements(Node.java:403)
	at com.sap.tc.webdynpro.progmodel.context.Node.getElementList(Node.java:346)
	at com.sap.tc.webdynpro.progmodel.context.Node.getElements(Node.java:334)
	at com.sap.tc.webdynpro.progmodel.context.Node.size(Node.java:718)
	at com.xxx.wd.MainComp.filter(MainComp.java:298)
	[...]
	at com.sap.tc.webdynpro.progmodel.generation.DelegatingComponent.doInit(DelegatingComponent.java:95)
	[...]

com.xxx.wd.* comes from the WD project; com.xxx.sessionfacade.ejb.ManagerSBBean comes from the EJB project, as com.xxx.business.dao.SomeDAO does, too!

Already restartet the server --- and no, the classloaders don't seem to have had a simple hiccough

Thanks in advance & best regards

Detlev

Accepted Solutions (0)

Answers (1)

Answers (1)

detlev_beutner
Active Contributor
0 Kudos

Resolved. For details see