JBoss EAP 6.4 and 7.0 fails to starts up when resolving an expression with the default value containing a '$' at the end
Environment
- Red Hat JBoss Enterprise Application Platform (EAP) 6.4.x, 7.0.x
Issue
JBoss EAP 6.4 and 7.0 fails to starts up when resolving an expression with the default value containing a '$' at the end.
For example, when I configured the following system property in standalone.xml:
<system-properties>
<property name="regex_prop_test" value="${my.regex.test:^default$}"/>
</system-properties>
Then JBoss failed to start-up with the following ERROR message:
ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS014612: Operation ("add") failed - address: ([("system-property" => "regex_prop_test")]) - failure description: "JBAS013494: Incomplete expression: ${my.regex.test:^default$}"
Resolution
This is a bug reported and fixed in upstram JIRA Content from issues.jboss.org is not included.WFCORE-1399. The following buzilla and JIRAs were created to backport the fix. This will be fixed in future releases:
- EAP 6.4.x: <This content is not included.https://bugzilla.redhat.com/show_bug.cgi?id=1443209>
- EAP 7.0.x: <Content from issues.jboss.org is not included.https://issues.jboss.org/browse/JBEAP-10406>
- EAP 7.1.0: <Content from issues.jboss.org is not included.https://issues.jboss.org/browse/JBEAP-10410>
You can workaround this issue by using EAP 6.4 new feature "nested expression" like the following:
<system-properties>
<property name="default_regex" value="^default$"/>
<property name="regex_prop_test" value="${my.regex.test:${default_regex}}"/>
</system-properties>
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.