Thursday, 7 July 2011

Starting a Coherence Server From WLS 10.3.4 Console

Decided it might make sense to use Node Manager to stop/start my stand alone coherence servers which will be accessed by the WebLogic managed server instances as storage disabled members. The process is pretty straight forward and is shown in this blog entry below. However there is one thing to be aware of.

In my example I wanted to use Coherence 3.7 and so to do that I needed to add the following to the "Server Start" Classpath field


Once I did that and tried to start the Coherence Server from the admin console , using node manager it failed with an error as follows.

Jul 8, 2011 4:36:25 AM> <INFO> <NodeManager> <Server output log file 
 Exception in thread "Main Thread" java.lang.NoClassDefFoundError: 
 Caused by: java.lang.ClassNotFoundException: 
         at java.lang.ClassLoader.loadClass(
         at sun.misc.Launcher$AppClassLoader.loadClass(
         at java.lang.ClassLoader.loadClass(
The poblem here is if you leave the classpath blank in the startup properties in the console configuration, then the two minimal jars (weblogic.server.modules.coherence.server_10.3.4.0.jar and coherence.jar) that are required are added for you. Once you specify a non-empty classpath (which is what I did), then you have to explicitly include those jars plus any others you want.

So what I needed was the following.


Once started the Log file for the coherence server exists on the file system as follows:


The PID for the server is found here, I normally add that to the log file but it's not possible when starting Coherence this way.


1 comment:

Anonymous said...

Interesting post. Thank you!