Skip to Content
Former Member
Jun 28, 2008 at 02:58 PM

MDM Java API 2 NoClassDefinitionFound Error


Hello Friends:

UserSessionContext usrSessCnxt = wdThis.getUserSessionContext();
AttributeSchema  attrSchema = MetadataManager.getInstance().getAttributeSchema(usrSessCnxt);

When I am executing the above two lines, I got this error today while working on a Web Dynpro iview using MDM Java API. The code

was failing exactly at the second line. First line, UserSessionContext

is initializing perfectly.

java.lang.NoClassDefFoundError: com/sapportals/connector/connection/ConnectionFailedException






Yes, I decompiled the MDM Java API classes and found the class JcaConnectionAccessor class with reserverConnection method. It only can throw ConnectionException. Apparently, the program wants to

throw Connection FailedException, which could not be found so, it is an irrevocable error so the Java

VM is crashing.

But there is one interesting thing. When I ran the same code pieces in a stand-alone Java program, it

runs perfectly ????

One more side fact, the Java MDM API jars I have, when I tested with "Java -jar mdm-core.jar"

command gives me as version.When run the same command on the MDM Server Jar files, I

get Also, when I check the version of the repository in MDM Console it is shown as I beleive this doesn't cause the problem, because the last digits only represents some hot


The reason why does the Java code works and not the Web Dynpro application ???

Appreciate your help,

Prasad Nutalapati