jQuery in Action, 3rd edition
The moose likes Websphere and the fly likes websphere network deployment v6.1 load-balancing for local ejb client Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "websphere network deployment v6.1 load-balancing for local ejb client" Watch "websphere network deployment v6.1 load-balancing for local ejb client" New topic

websphere network deployment v6.1 load-balancing for local ejb client

leon xian

Joined: Mar 10, 2008
Posts: 2
Hi, does anyone know if there is some workaround to break process affinity in websphere application server (network deployment v6.1) so the workload manager can route part of local ejb requests to remote node machine(s) in a cluster?

According to all the documentation we've read about load-balancing in websphere application server, all ejb requests that come from a local ejb client will be processed within the same application server. I understand this is forced for performance reason. But in my case, I need the load-balancing to be able to forward part of the requests to other nodes in the same cluster.

Also, this ejb client has to be running as a cluster singleton in my application.

Is this possible by any means?

Thanks very much for any hint.
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
In EJB terminology, "local" means "in the same JVM". Therefore, if you're using an EJB's local interface it will always be executed in the same JVM (Server) as the client.

If you want calls to EJBs to be load balanced, you must use the EJB's remote interface.
[ March 10, 2008: Message edited by: Merrill Higginson ]

Consultant, Sima Solutions
leon xian

Joined: Mar 10, 2008
Posts: 2
Thanks for your reply... Maybe I should have described the scenario in more details.

I have a cluster set up in Websphere to include 2 application servers (nodes). A ejb client is running in one of the 2 servers (the same JVM where the application server runs) to submit requests to some ejb deployed in the cluster.

What I want to achieve is the load-balancing across the entire cluster so that some ejb requests will be handled locally in one server and others will be processed in another server. Because of "Process Affinity" in
Websphere, all the ejb requests submitted by that client were procssed
only in the local application server and weren't distributted to the remote server (JVM) eventhough round-robin has been set.

For my ejb application deployed in Websphere, there's only remote interface defined. And the ejb client always uses JNDI lookup to find the EJB.

The same application works fine in JBoss which allows overriding of ejb invoker interceptor so that local ejb client can choose between local and remote interface for load-balancing. Check the link from JBoss:


Not sure if Websphere provides something similar (it is supposed to...)
Peter Fernandes

Joined: May 21, 2008
Posts: 10
How about using Data Replication Services (DRS)?

Patrick Finnegan
Ranch Hand

Joined: Mar 05, 2002
Posts: 179
You may need to connect to the rmi port on the Deployment manager rather than the rmi port on the node. The DM should load balance the requests over the nodes.
Ankit Thakkar
Ranch Hand

Joined: Apr 29, 2005
Posts: 33

Hi Patrick,

could you please provide more info on your suggestion? We have the smililar requirement to load balance RMI transactions and really stuck up with this part.


- Ankit
I agree. Here's the link: http://aspose.com/file-tools
subject: websphere network deployment v6.1 load-balancing for local ejb client
It's not a secret anymore!