You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "David Jencks (JIRA)" <ji...@apache.org> on 2015/10/15 23:27:05 UTC

[jira] [Created] (FELIX-5079) [DS] Not enough configuration listeners to deal with regions

David Jencks created FELIX-5079:
-----------------------------------

             Summary: [DS] Not enough configuration listeners to deal with regions
                 Key: FELIX-5079
                 URL: https://issues.apache.org/jira/browse/FELIX-5079
             Project: Felix
          Issue Type: Bug
          Components: Declarative Services (SCR)
    Affects Versions: scr-2.0.2
            Reporter: David Jencks
            Assignee: David Jencks


We implemented the global extender flag that lets DS deal with components in all regions (or in more spec terms all bundles everywhere in the framework regardless of visibility to the DS bundle)  but there is only one ConfigurationListener registered with the DS bundle context.  Obviously if there are different CA's in different regions this won't work.

Another twist is that (apparently, according to Tom Watson) just because a bundle A can see a particular CA instance B does not mean that B can see a ConfigurationListener registered by A.

This might work:
1. When a bundle to be extended arrives, and it has configurable components in it, we register a ServiceTracker for config admin with that bundle.
2. When the service tracker detects a CA, we check that it is a CA compatible with the DS CA class, and whether we already know about it.
3. if it's our kind of CA and we don't know about it, then we register a ConfigurationListener with the CA's bundle.
4. When the last service tracker knowing about a particular CA indicates the CA is leaving we unregister the ConfigurationListener (or when the last bundle using that CA stops)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)