cancel
Showing results for 
Search instead for 
Did you mean: 

Best way to deploy an JCA Adapter

Former Member
0 Kudos

Hi there,

I'm currently working on an XI resource adapter. For this, I created a connector project in eclipse based on the SAP sample adadpter. The connector's rar-file is assembled in an EAR project. Whe I try to deploy the EAR, I'm facing some problems (deployment was done via Deploy Service in Visual Admin):

<b>1. Libraries not found:</b>

guidgenerator.jar

sapj2eeclient.jar

Deployment is aborted due to NoClassDefFoundError, so I have to assemble both liraries to my EAR file. How do I have to register those libs in my connector-j2ee-engine.xml?

<b>2. ZipException after starting the adapter</b>

When I've added the libs to the package, deployment seems to work. After deployment, the constructor of class MySPIManagedConnectionFactory is called. But then, immediately the method finalize is called. (?!?)

This procedure ends up in a ZipException, this is really astonishing, because the exception is thrown in a context, where no other library or jar is called.

Here's the Message :

java.util.zip.ZipException: The system cannot find the path specified

at java.util.zip.ZipFile.open(Native Method)

at de.myadapter.MySPIManagedConnectionFactory.stopMCF(MySPIManagedConnectionFactory.java:1194)

at de.myadapter.MySPIManagedConnectionFactory.finalize(MySPIManagedConnectionFactory.java:1124)

Does anybody know this strange behavior? Help is highly appreciated and will be rewarded!!!

Cheers,

Matthias

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

may be helpful...

from

Yallabandi

Former Member
0 Kudos

Yallabandi,

thanks for your reply!

Regarding the libraries, I have those libraries in my eclipse project. But I need the correct J2EE server library names for both jars, in order to create a reference in my connector-j2ee-engine.xml.

Something like:

<loader-name>library:com.sap.aii.af.lib</loader-name>

Do you know, where I can lookup these names for that libraries?

Cheers,

Matthias

stefan_grube
Active Contributor
0 Kudos

Look at sample_ra.sda how to assign the library references.

You have to create the same sda structure for your adapter. So pack jar -> rar -> sda.

It is not allowed to add the libraries to the EAR.

Regards

Stefan