Tim Fox and I were having a discussion on
http://jira.jboss.com/jira/browse/JBMESSAGING-957 about how to give identity to servers in
a cluster. Wanted to bring it here to get inputs from others who may face similar issues
and in particular from the JON folks.
Issue is basically that there are various places where code needs to give some kind of
identity to a server:
1) Tomcat engine if mod_jk is used (jvmRoute attribute).
2) JBoss Messaging if clustered.
3) HAPartition to prevent two incarnations of the same server joining the cluster.
Tim and I are discussing setting the name for a server via run.sh, perhaps using something
like what's done with $JBOSS_HOST and -b in jboss_init_redhat.sh:
JBOSS_NODE_NAME=${JBOSS_NODE_ID:+"-i $JBOSS_NODE_ID"}
| #define the script to use to start jboss
| JBOSSSH=${JBOSSSH:-"$JBOSS_HOME/bin/run.sh -c $JBOSS_CONF $JBOSS_BIND_ADDR
$JBOSS_NODE_ID"}
The above presumes the addition of a new startup switch '-i' or --id; a system
property could be used as well.
Basically just wanted to get any comments any one had adding this sort of thing, e.g.
1) what are your use cases for wanting an id for a server?
2) does it need to be persistent across restarts (i.e. can't be randomly generated at
runtime or something)?
3) Any constraints on the id? E.g. JBM wants an int id, which isn't really appropriate
for the jvmRoute or HAPartition use cases.
4) Any thoughts on setting it based on the local env via the startup script? Would the
JON folks want to do it some other way?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045578#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...