[jboss-dev-forums] [Design of the JBoss EJB Container] - Change to make PooledInvokerProxy.getServerHostName() return

ScottMarlow do-not-reply at jboss.com
Thu Mar 8 18:02:42 EST 2007


I'm working on a prototype for integrating a HA-Singleton to a "FavorSingleton" load balancer policy (I will post in the clustering forum when it is more complete.)  Its for pinning a ejb 2.x bean to a particular server that the load balancer can always find.  

If load balancing policy's work with ejb3 beans, than all the better.  :)

In my load balancing policy, I am in need of more specific information from the opaque objects passed in.  I would like to be able to get something that identifies the server hostname + some port number that it is listening on.  

I'm thinking of hacking PooledInvokerProxy.getServerHostName() to return the server hostname and pooledInvokerHA listening port:

getServerHostName()   // in class PooledInvokerProxy
  |    {
  |       return address.address + ":" + address.port;
  |    }
  | 

Or perhaps the Invoker interface could be enhanced to have a getServerPort() method.  I suppose that some implementations might not have a server port number to return, so they wouldn't work with load balancer policies that need that.

Comments?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4026456#4026456

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4026456



More information about the jboss-dev-forums mailing list