[
https://issues.apache.org/jira/browse/FELIX-5038?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Raymond Augé closed FELIX-5038.
-------------------------------
Resolution: Abandoned
This issue has not seen activity for at least2 years. So we're closing it.
If however, you feel this was done in error or because you think you might wish
to participate in resolving the issue please don't hesitate to reopen it.
> Configuration properties are not synchronized with config files when adding
> Metatype information
> ------------------------------------------------------------------------------------------------
>
> Key: FELIX-5038
> URL: https://issues.apache.org/jira/browse/FELIX-5038
> Project: Felix
> Issue Type: Bug
> Components: File Install
> Reporter: Gregor Zurowski
> Priority: Minor
>
> In a Karaf/Blueprint setup, I noticed an issue related to Config Admin and
> Felix File Install where configuration properties are not synchronized with
> the corresponding configuration file once Metatype information is added to
> the bundle.
> In a simple test bundle, the configuration properties are implemented using
> property placeholders in Blueprint as follows:
> {code:title=blueprint/blueprint.xml}
> [...]
> <cm:property-placeholder id="config-test-blueprint-placeholder"
> persistent-id="test.config" update-strategy="reload">
> <cm:default-properties>
> <cm:property name="test.property.1" value="Test 1" />
> </cm:default-properties>
> </cm:property-placeholder>
> [...]
> {code}
> The corresponding configuration file in $KARAF_HOME/etc looks as follows:
> {code:title=etc/test.config.cfg}
> [...]
> test.property.1 = Test Value 1
> [...]
> {code}
> When adding the following Metatype information, the synchronization mechanism
> stops working, i.e. changes made in OSGi config admin using webconsole are
> not written back to the configuration file:
> {code:title=metatype/metatype.xml}
> [...]
> <AD name="Test Property 1" id="test.property.1" required="true"
> type="String" default="Default value 1" description="This is test
> property 1" />
> [...]
> {code}
> The only way to fix synchronization is to add the following attribute
> definition to Metatype:
> {code:title=metatype/metatype.xml}
> [...]
> <AD name="felix.fileinstall.filename" id="felix.fileinstall.filename"
> required="true" type="String" default="" description="Don't
> modify this property!" />
> [...]
> {code}
> This has been also discussed on the Karaf users mailing list, see:
> http://karaf.922171.n3.nabble.com/Blueprint-Property-Placeholders-with-Metatype-Information-td4042619.html
--
This message was sent by Atlassian Jira
(v8.3.4#803005)