felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Felix Meschberger (JIRA)" <j...@apache.org>
Subject [jira] Closed: (FELIX-612) ConfigurationAdmin.createFactoryConfiguration should not persist Configuration
Date Wed, 06 Aug 2008 08:34:44 GMT

     [ https://issues.apache.org/jira/browse/FELIX-612?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

Felix Meschberger closed FELIX-612.

Deployed snapshot version 1.0.2-20080806.083202-1.

Closing this now.

> ConfigurationAdmin.createFactoryConfiguration should not persist Configuration
> ------------------------------------------------------------------------------
>                 Key: FELIX-612
>                 URL: https://issues.apache.org/jira/browse/FELIX-612
>             Project: Felix
>          Issue Type: Bug
>          Components: Configuration Admin
>    Affects Versions: configadmin-1.0.0, configadmin-1.0.1
>            Reporter: Felix Meschberger
>            Assignee: Felix Meschberger
>             Fix For: configadmin-1.0.4
> Currently the ConfigurationAdmin.createFactoryConfiguration methods immediately persist
factory configurations upon creating them. This is not really incorrect as per the spec.
> The problem comes with this opening the gate for potential garbage configuration to remain.
Consider this sample method:
>     public void createGarbage( String factoryPid )
>     {
>         getConfigurationAdmin().createFactoryConfiguration( factoryPid );
>     }
> This method creates a new factory configuration object on each call and immediately drops
any reference to it. Because the configuration PID of the configurations returned is created
randomly, there is no way to ever retrieve this configuration again. Why ? getConfiguration
cannot be used because the PID is unkown and listConfigurations will not return it because
the configuration has no properties yet.
> So in the interest of not potentially producing garbage, the createFactoryConfiguration
method should not immediately persist the configuration object.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message