cancel
Showing results for 
Search instead for 
Did you mean: 

NoClassDefFoundError after adding third-party jars... need help

former_member186148
Active Participant
0 Kudos

Hello SDN! I'm strongly need your help.

I'm developing a WD Java application which contains followed DCs:

AppDC is a Web Dynpro which contains application-depended views, controllers, runnable WD app.

ExporterDC is a Web Dynpro DC with no applications, this is helper DC for export table data into Excel and other formats

MainDC is a Web Dynpro DC with no applications, this is a basis DC. This DC contains some common useful views and controllers which used by AppDC

JavaDC is a Java DC (not J2EE Server Component) which contains my own common helper classes

LibsDC is a External Library DC which contains third-party jars used by apps

J2eeDC is a J2EE Server Component Library DC which is just a wrapper for LibsDC

These DCs has followed dependencies:

LibsDC is Used DC for J2eeDC (both assemble and compile types) with Build-time dependency

J2eeDC is Used DC for JavaDC (defLib) with Build-time and Run-time dependencies

JavaDC is Used DC for ExporterDC, MainDC and AppDC (both assemble and compile types) with Build-time dependency

ExporterDC is Used DC for MainDC (both assemble and compile types) with Build-time dependency

MainDC is Used DC for AppDC (both assemble and compile types) with Build-time dependency

Build perform without errors. I can deploy build results of J2eeDC, ExporterDC, MainDC and AppDC. But when I call my application I get NoClassDefFoundError at row of ExporterDC where is the first call of class from JavaDC which has reference to classes from third-aprty jars.

Please note that I'm not using third-party jars in WD DCs, these jars used only in JavaDC.

I've read quite many threads and blogs but I can't to find solution.

P.S. I'm working with NW 7.0 SP 14, all DCs are local.

Hell will be apriciated!

Regards, Lev

Accepted Solutions (1)

Accepted Solutions (1)

former_member185086
Active Contributor
0 Kudos

Hi

Very first check with kind of issue.

How u public the jar/files of external library dc Public as file or publish as archive

if as file then change it to publish as archive for compilation as well as assembly build it and then redefine the uses ( Dont deply EL DC only build is required )

Let [see|https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/12177] [original link is broken] [original link is broken] [original link is broken];

Best Regards

Satish Kumar

former_member186148
Active Participant
0 Kudos

Hi!

Thank you for reply!

Here are few jars in Entities for assembly PP and compile PP in ExtLibrary DC. In "properties" tab property "type" has value "Archive" for every of jar in Entity.

About blog - this blog about situation when Web Dynpro DC use third-party jar. But in my situation Web DC uses Java DC, there is no references to jars in code of WD DC. Only Java DC references to jars.

regards, Lev

Answers (1)

Answers (1)

former_member186148
Active Participant
0 Kudos

I found solution working for me.

I'll try to create a detailed weblog about it.

(i know that it will be yet another webog about ext. libraries nevertheless I think that it may be useful).

Regards, Lev