users@glassfish.java.net

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

From: Stephen Connolly <stephen.alan.connolly_at_gmail.com>
Date: Wed, 5 Dec 2007 14:41:48 +0000

Ahhh but I was thinking of setting the jndi name of BReomte on cluster
A to point to the EJB on cluster B... i.e. create a remote reference
on A for the BRemote on cluster B, then if the app client is launched
from cluster A it will inject the ARemote for cluster A as it sees
that itself, and the BRemote from the reference for it on cluster A
which is pointing to cluster B, so it will get the reference to
cluster B.

I have no idea how to do such a config, but I would thing that's what
you want to do... (I saw something similar to this on a WebSphere
training course the other week so I'm not sure if glassfish has an
easy mechanism to do this)

On Dec 5, 2007 1:29 PM, <glassfish_at_javadesktop.org> wrote:
> 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
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>