users@glassfish.java.net

Re: Adding Cluster Support for Sun GlassFish Enterprise Server by asadmin?

From: <glassfish_at_javadesktop.org>
Date: Thu, 25 Jun 2009 00:17:36 PDT

I am a bit confused by your requirement here. One thing you must note is that ALL distributions
of GlassFish V2 have clustering support by default. The only catch is that a domain that starts
its life as a domain that does not support cluster can support clusters later in life only via this
special admin GUI procedure.

So, you can always create a domain with a profile named "cluster" by doing say "asadmin create-domain --profile cluster ..." and the created domain will have cluster support [b] right from the beginning[/b] and for such a domain, since cluster support is already there, no special procedure is needed.

In essence, if you are expecting a cluster support, why not do it right from the beginning, rather than looking for a scripted way of adding it after the fact?

The reason it does not have asadmin support (and only GUI) is it is a GlassFish v2 limitation
that any domain can't support clusters on demand. It needs to have some special switches
turned specific way for this to happen. This situation will change with GlassFish v3 and that
means we need to deprecate such a command in v3. Since I knew this at the time I did this
for v2, we chose to provide this facility only on admin console (GUI).

Notwithstanding the above, since I coded this, I can suggest a JMX hack for this, (like I have
suggested to someone else), but I'd really want you to refrain from it.

Regards,
Kedar
[Message sent by forum member 'km' (km)]

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