Search code examples
wildflywildfly-8

How to set node name in WildFly-8.2.0 domain mode


I can set this in standalone mode by using -Djboss.node.name=nodeA. I wonder, how can this be set for each node managed in domain mode?

I found that there is a small change in the node name when it is in domain mode compared to standalone mode. In standalone mode it is nodeA but in domain mode it is master:nodeA. Is there any way to make them the same?


Solution

  • What you're seeing in domain mode is the fully qualified name. It is telling you the host name, followed by the node name.

    If you look in your host-master.xml, you will see the root tag looks like this:

    <host name="master" xmlns="urn:jboss:domain:2.2">
    

    If you change the host name to something like main, you will find that your fully qualified node name is main:nodeA.

    You could remove the name attribute from the <host> (the host.xml file doesn't have it), but I wouldn't recommend it, because it can make things a bit more confusing in terms of management if you have a multiple hosts.