System property substitution in ejb-jar.xml or jboss.xml is not working in EAP
Issue
- While migrating from JBoss EAP 4.2.3 to JBoss EAP 5.x the system properties substitution is not working for ejb-jar.xml file. We defined the System properties in xml file as and placed the xml file in the $PROFILE/deploy directory.
<server>
<mbean code="org.jboss.varia.property.SystemPropertiesService" name="jmx.service.test.props:service=TestSystemParameters">
<attribute name="Properties">
testPropertyOne=TestValueOne
testPropertyTwo=TestValueTwo
</attribute>
</mbean>
</server>
We are replacing the "testPropertyOne" in ejb-jar xml environment property, but it is not replacing.
<session>
<ejb-name>CaseAssignmentServiceBean</ejb-name>
<ejb-class>test.service.CaseAssignmentServiceBean</ejb-class>
<env-entry>
<env-entry-name>DB2Schema</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>${testPropertyOne}</env-entry-value>
</env-entry>
</session>
- 5.1.x order of deployment / reading of properies
- Similarly Properties substitution is not working inside the "META-INF/jboss,xml" file as well.
Environment
- JBoss Enterprise Application Platform (EAP)
- 5.x.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
