Is there any way a member can leave a cluster ?

Hi,
I have a java client and a cache server running , the function of java client is that it should get a Named cache and write something to the cache.
Once this is done the client (which now is a member in a cluster) should leave the cluster and continue with other functions in the client.
Is there anyway we could make the client leave the cluster after performing required action.
Any help will be highly appreciated.
Thanks.

Hi,
Alternatively to Coherence*Extend you can force JVM to leave a cluster.
CacheFactory.getCluster().shutdown();This line will forc JVM to leave a cluster, and all instances of NamedCache will become invalid.
To rejoin cluster later just call
CacheFactory.getCache(...);And it will automatically join cluster again before returning you fresh instance of NamedCache.
Interesting thing is what you can connect to different cluster this way, just adjust cluster config before rejoining cluster (see Re: Multiple clusters on same JVM
PS I'd better keep your client node storage disabled for this case

Similar Messages

Maybe you are looking for