0

I have some bundles started in karaf and want to change their configuration during start. I created class that implements ConfigurationPlugin and registered it in karaf. When I installed bundle, my configuration plugin was invoked and changed configuration, but blueprint set old config value to the bundle.

How can I use this ConfigurationPlugin for this goal?

Blueprint is very simple:

<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
       xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0">

    <cm:property-placeholder persistent-id="my" update-strategy="reload">
    </cm:property-placeholder>
    <bean id="serviceBean" class="com.mycompany.blueprint.MyServiceImpl">
        <property name="prop" value="${mydb.password}" />
    </bean>
</blueprint>

Configuration file contains only one encrypted property. It should be somehow decrypted using another bundle during creation.

  • a bit more meat is needed here ... how does your blueprint configuration look like? any more participants in that game, for example do you also have configuration files? – Achim Nierbeck Sep 17 '15 at 11:14
  • As I found here https://issues.apache.org/jira/browse/FELIX-4599 ConfigurationPlugin will be invoked not in all cases and seems can't be used for this purpose. – Pavlo Vasylchenko Sep 17 '15 at 11:18

0 Answers0