users@glassfish.java.net

Re: ACC access to multi clusters, different Beans in one enterprise applica

From: <glassfish_at_javadesktop.org>
Date: Wed, 05 Dec 2007 05:29:40 PST

Hi Stephen,

thanks for your answer. We've tried to specify with jndi specific attributes for the @EJB annotation. For example, we tried the following:

...
@EJB(mappedName="corbaname:iiop:hostname:clusterAport#test.ARemote")
public static ARemote aService;
    
@EJB(mappedName="corbaname:iiop:hostname:clusterBport#test.BRemote")
public static BRemote bService;
...

This works, so the client application runs in the ACC and connects to both clusters A and B at the same time. In case of multiple ServerInstances for each cluster the FailOver is also possible - we've tried it. So we think that an ACC is - in principle - able to connect to differnt clusters at the same time.

But we hoped, that there is an other way (a more automatically way) to specify the cluster nodes for the injection mechanism. The GlassFish knows the actual cluster setup (how many clusters are defined and which remote interfaces are available in which cluster). I think, it's not a good idea hardcode clusters hostname and port (one of each) in the annotation. Maybe there is a way that GlassFish automatically sets the right parameters to the deployment descriptor at deploy time? Hope so.

thanks in advance,
 Frank
[Message sent by forum member 'fmeili' (fmeili)]

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