users@glassfish.java.net

Telling a client through DNS available IIOP Endpoints (for an EJB Cluster)

From: <glassfish_at_javadesktop.org>
Date: Wed, 24 Sep 2008 07:14:41 PDT

Hi,
I have a question about IIOP failover/high availability (with GlassFish, in memory replication).

[quote]However, a client should have at least two endpoints specified for bootstrapping purposes, in case one of the endpoints has failed.
[url=http://docs.sun.com/app/docs/doc/819-3679/fxxqs?a=view]Chapter 11 RMI-IIOP Load Balancing and Failover[/url]
[/quote]

Up to now I realised this by adding two target-servers to the sun-acc.xml and then running:
appclient -xml my-sun-acc.xml -client myEJBClient.jar

That's my sun-acc.xml:
[...]
<client-container>
  <target-server name="server1" address="192.168.0.1" port="33700"/>
  <target-server name="server2" address="192.168.0.2" port="33700"/>
  <property name="com.sun.appserv.iiop.loadbalancingpolicy" value="ic-based"/>
[...]

If both servers are unavailable, but e.g. server3 and server4 are running, my client doesn't run, because the client just knows the address of server1 & server2.

Can I also use a DNS lookup for that purpose? I mean, I edit my sun-acc.xml:
[...]
<client-container>
  <target-server name="server" address="servers.domain.com" port="33700"/>
  <property name="com.sun.appserv.iiop.loadbalancingpolicy" value="ic-based"/>
[...]

and the dns lookup gets e.g. 4 addresses, 192.168.0.1, .2, .3 and .4?

Would this work or is this not possible? Maybe, the client does not do a dns lookup or just tries the first ip he gets from the dns lookup.


It would be nice if some can help me, because I cannot test this on my local machine and I have to know this for a paper.

Greetings
Hannes
[Message sent by forum member 'hannes2k' (hannes2k)]

http://forums.java.net/jive/thread.jspa?messageID=301291