java.lang.ClassNotFoundException:MemberInvokeTake” exception.

java.lang.ClassNotFoundException:MemberInvokeTake” exception.

book

Article ID: KB0089363

calendar_today

Updated On:

Products Versions
TIBCO ActiveSpaces -
Not Applicable -

Description

Description:
p { margin-bottom: 0.1in; direction: ltr; line-height: 120%; text-align: left; widows: 2; orphans: 2; }

Call MemberInvacable class throws “java.lang.ClassNotFoundException: MemberInvokeTake” exception.


Symptoms:
p { margin-bottom: 0.1in; direction: ltr; line-height: 120%; text-align: left; widows: 2; orphans: 2; }

Caused by: com.tibco.as.space.ASRemoteException: java.lang.ClassNotFoundException: MemberInvokeTake

at com.tibco.as.space.impl.InvocationDispatcher.invokeMember(InvocationDispatcher.java:222)

Caused by: java.lang.ClassNotFoundException: MemberInvokeTake

at java.net.URLClassLoader$1.run(Unknown Source)

at java.net.URLClassLoader$1.run(Unknown Source)

at java.security.AccessController.doPrivileged(Native Method)

at java.net.URLClassLoader.findClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Unknown Source)

at com.tibco.as.space.impl.InvocationDispatcher.invokeMember(InvocationD


Cause:
mis-configuration

Issue/Introduction

java.lang.ClassNotFoundException:MemberInvokeTake” exception.

Resolution

p { margin-bottom: 0.1in; direction: ltr; line-height: 120%; text-align: left; widows: 2; orphans: 2; }

For remote method,put AS lib in java.ext.dirs argument. Example:


java -Djava.ext.dirs=%AS_HOME%/lib;%AS_HOME%/examples/java -jar as-agent.jar -discovery tcp

java -cp %AS_HOME%/examples/java/Examples.jar remote.InvokeClient -discovery tcp

Note: if you are running a simple java code, please put the java class in the jar file, else it won't work. You can follow the steps as below:


1). Put the class in the jar file. Assume Examples.jar. The Examples.jar is located at /home/morphy/Download/asSupport/out on my side.

2). Start the agent with the following command:

java -Djava.ext.dirs=/home/morphy/AS_HOME/AS212_HOME/as/2.1/lib:/home/morphy/Downloads/asSupport/out -jar as-agent.jar

3). start the class with the follwoing command:

java -cp /home/morphy/AS_HOME/AS212_HOME/as/2.1/lib/as-common.jar:/home/morphy/Downloads/asSupport/out ASInvokeSampleClient