on 12-11-2008 3:28 PM
Hi everybody,
I need to use several xml utilities distributed as jars. Following this [blog|https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/12177] [original link is broken] [original link is broken] [original link is broken]; I did as follows:
- copied my jars in the libraries folder of an external library DC
- added all of them to both assembly and compilation public part
- referenced the api pp from my WD client (build dep)
- referenced the ass pp from a J2EE server component (library) (build dep)
- referenced the library from my WD client from project properties-> library references etc.
[I have already used this procedure for java classes and it works]
When it comes to jars it will give class not found.
What I noticed is that the J2EE library .sda deployable archive does not include the ass_pp nor the jars from the external library.
In the J2EE library project the .jars are actually there in the folder:
<project path>\_compgendefaultpublicdefLiblibjava
however the sda will only have
- META-INF folder
- server folder
Appearently the library will only correctly include assembly public parts from DCs of type other than External Library (i.e. it works ok with assembly pp from WDJ DCs).
Can anyone please help?
Thanks
Vincenzo
Hi,
Earlier i face the similar Problem ,Which i resolved by including Both Assembly an Compilation PP in WD dc.
i have not tried this approach in 7.0 for External libs but you can try the following locally for NW 7.0 and see if it works:
if you have any EA DC in the Architecture you can replace the SDA(J2EE Server Component DC) with EA Dc and follow the approach mentioned in the Blog for CE 7.1.
instead of giving DC Run Time usage,you have to specify the EA dc shared reference in WD Application property.
Siddharth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I tried this as well, but it is very empirical, and it didn't work for me either:
unzip your jars
recursively decompile all the .class
add the obtained .java files to your project with their respective folders.
however your decompiler might generate odd java sources which often won't compile at all and need manual editing (!).
Any suggestion?
Thanks, Vincenzo
Hi Vincenzo,
You can give a try to the blog mentioned by Durga.
In this approach, the J2EE server library is not required at all. You just need to create compilation (API) and Assembly (SDA) type of Public Parts of the External Library DC, and consume them as Used DC in your Web Dynpro Project, with Build Time Checked.
In case of Java project, your technique may have worked because, Java projects are not deployables, while using Web Dynpro and EA projects, the JARS to be used must also be available in a Deployable format for use. Hence, remember to add the SDA type public part to the Web Dynpro DC.
Regards,
Alka.
I manually added the required jars to the root of the .ear. Of course you have to do this every time you rebuild the DC.
Moreover, you cannot use the autogenerated archive from DI. I tried every other option, but only this worked.
Thanks, regards, Vincenzo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Which service pack are you using?
Thanks & Regards,
Lokesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, thanks for replying.
I have used that technique several times before, with java classes, and it actually works.
However in this case I can see that the jars are correctly packed in the WDJ archive, but the error is there all the same.
Appearently jars aren't searched through during classloading.
Any suggestion?
Thanks kind regards
Vincenzo
User | Count |
---|---|
96 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.