What I need is the following
Java clients invoking EJBs in a WebLogic cluster.
I read from the docs that there is a "direct-model", where a client lookup a stub using JNDI, which returns a clusterable stub maching ID, and allow multiple method invocation. The stubs use load balacing algorithm to choose which server to call.
There is also a 'indirect model' where client lookup up stub using JNDI and is returned with a clusterable stub which the client calls create on and is pinned to a server.
Problem is with how could I get the stubs/skeletons to be generated in both models. I use Web Gain visual cafe 4.1. Is the Clusterable options from Project options->Configure Deployment Descriptor->Target Options->Clustering
Home is Clusterable
Stateless Bean is clusterable
Stateless Bean method is idempotent
what this is all about?
Let me get it right? Is it the STUB that is doing the intelligent bit and route call to different servers?
Also, as for the JNDI lookup in the server, I saw that the code could be called like
where p is the property to be passed in the InitialContext used for looking up.
But surely, myCluster is not a machine name, it is barely a clustername setup in weblogic.properties, which the client, seating on another machine on the same LAN would have no knowledge of. Would it work if I just use a JNDI service from any machine within the cluster. e.g. if I myCluster contains server1,server2,server 3 then
but surely, that defeats the whole purpose of resilience??, what if server1 goes down??
Or does it need a 'round-robin' DNS server routing the JNDI request to different machines within the cluster. All the documents talks a lot about 'downloading' stubs, is that all transparent to the client?
Sorry if I am a bit naive, but I am new to clustering!