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

Tom Watson updated FELIX-6159:
------------------------------
    Fix Version/s: scr-2.1.18

> Possible IllegalStateException for deleted Configuration from config admin
> --------------------------------------------------------------------------
>
>                 Key: FELIX-6159
>                 URL: https://issues.apache.org/jira/browse/FELIX-6159
>             Project: Felix
>          Issue Type: Improvement
>          Components: Declarative Services (SCR)
>    Affects Versions: scr-2.1.16
>            Reporter: Tom Watson
>            Priority: Major
>             Fix For: scr-2.1.18
>
>
> {{org.apache.felix.scr.impl.manager.RegionConfigurationSupport}} holds the 
> support in SCR for dealing with configurations for components.  This class 
> does not handle the various methods on {{org.osgi.service.cm.Configuration}} 
> that can throw an {{IllegalStateException}} if the configuration is deleted, 
> for example:
> * org.osgi.service.cm.Configuration.getPid()
> * org.osgi.service.cm.Configuration.getProperties()
> * 
> org.osgi.service.cm.Configuration.getProcessedProperties(ServiceReference<?>)
> * org.osgi.service.cm.Configuration.getFactoryPid()
> * org.osgi.service.cm.Configuration.getChangeCount()
> * org.osgi.service.cm.Configuration.getAttributes()
> This leaves SCR open to failing if the configuration has been deleted after 
> SCR has gotten the configuration from {{ConfigurationAdmin}} but before SCR 
> has been able to use the configuration to configure a component.  Instead of 
> having a catastrophic failure that bubbles the IllegalStateException up the 
> stack, SCR should handle the exception and treat it as if the configuration 
> was never found in the first place.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to