I have the following XML file on which I am trying to update the ss.host.name system property:
<server xmlns="urn:jboss:domain:3.0">
<extensions>
<extension module="org.jboss.as.clustering.infinispan" />
<extension module="org.jboss.as.connector" />
<extension module="org.jboss.as.deployment-scanner" />
<extension module="org.jboss.as.ee" />
<extension module="org.jboss.as.ejb3" />
<extension module="org.jboss.as.jaxrs" />
<extension module="org.jboss.as.jdr" />
<extension module="org.jboss.as.jmx" />
<extension module="org.jboss.as.jpa" />
<extension module="org.jboss.as.jsf" />
<extension module="org.jboss.as.logging" />
<extension module="org.jboss.as.mail" />
<extension module="org.jboss.as.naming" />
<extension module="org.jboss.as.pojo" />
<extension module="org.jboss.as.remoting" />
<extension module="org.jboss.as.sar" />
<extension module="org.jboss.as.security" />
<extension module="org.jboss.as.transactions" />
<extension module="org.jboss.as.webservices" />
<extension module="org.jboss.as.weld" />
<extension module="org.wildfly.extension.batch" />
<extension module="org.wildfly.extension.bean-validation" />
<extension module="org.wildfly.extension.io" />
<extension module="org.wildfly.extension.request-controller" />
<extension module="org.wildfly.extension.security.manager" />
<extension module="org.wildfly.extension.undertow" />
</extensions>
<system-properties>
<property name="ss.host.name" value="localhost" />
</system-properties>
</server>
My variable is defined as:
/server/system-properties/property[@name='ss.host.name']/@value
with a value of my name, JUSTIN. If I plug this XPath and XML into an XPath tester, it works fine, but the value is never updated when I deploy my project.
The deployment log has this:
Structured variable replacement succeeded on file /home/Octopus/Applications/DEV/com.foo.bar%3Aapp-configuration/1.0.0-SNAPSHOT_3/standalone.xml with format Xml
so I know that it is actually performing the replacement, but the value of ss.host.name is always localhost, I cannot get it to substitute my variable.
Am I going crazy here? I’ve fought with this for about 3 hours now, trying every single dumb XPath trick I can think of and absolutely nothing is working for me.