1
XSLTを使用してsystem-properties.xmlにプロパティを追加したいと思います。xslt jboss properties-service.xmlにテキストを追加
現在のXMLファイル:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE server>
<server>
<mbean code="org.jboss.varia.property.PropertyEditorManagerService"
name="jboss:type=Service,name=PropertyEditorManager">
</mbean>
<mbean code="org.jboss.varia.property.SystemPropertiesService"
name="jboss:type=Service,name=SystemProperties">
<attribute name="Properties">
my.project.property=This is the value of my property
</attribute>
</mbean>
</server>
私は、属性名= "プロパティ" の内側に新しいプロパティを追加します。
結果:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE server>
<server>
<mbean code="org.jboss.varia.property.PropertyEditorManagerService"
name="jboss:type=Service,name=PropertyEditorManager">
</mbean>
<mbean code="org.jboss.varia.property.SystemPropertiesService"
name="jboss:type=Service,name=SystemProperties">
<attribute name="Properties">
my.project.property=This is the value of my property
my.project.anotherProperty=This is the value of my other property
</attribute>
</mbean>
</server>
感謝。
良い質問、+1。私の答えは完全で、簡単でシンプルな解決策を見てください。 –